lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]



As integer will be a "visible" subtype, you can choose not to use
it.

How hard will it be to ensure that all the computations inside a given collection of functions are being done with floating point math?  I have a library for generating parametric paths, and I know all of its internal computations ought to be floating point -- both for reasons of speed and precision handling.  Will I need to explicitly convert any numeric arguments sent to that library to the float subtype?  Something like:

function path(x,y) 
   return internal_path( tofloat(x), tofloat(y) )
end ?


-Sven