lua-users home
lua-l archive

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


> Le 21 janv. 2015 à 20:56, Luiz Henrique de Figueiredo <lhf@tecgraf.puc-rio.br> wrote :
> 
>> Interesting approach, as math.random(), based on ansi C `rand()`, isn't really considered as a good random generator.
> 
> Lua 5.3 uses POSIX random instead of rand, in POSIX platforms.
> 
>> Personally, I did something analog, but as a change to the Lua source code, by defining a `luai_rand` macro in `luaconf.h`:
> 
> Lua 5.3 now supports macros l_rand and l_srand which can be set by the builder.
> 

Thanks for the information. 
This makes one more reason to migrate my code base to Lua 5.3 very soon. :-)

JLJ