lua-users home
lua-l archive

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

Roberto Ierusalimschy wrote:
> Here is a list of novelties in 5.0 beta (compared to 5.0 alpha). They
> should create no incompatibilities in "normal" programs.
> * The compiler does not change the order of operands for "commutative"
> operators. (I don't remember why, but I remember there was quite a
> discussion about that in the list.) (However, "a>b" is still translated
> to "b<a", and "a>=b" to "b<=a".)

IIRC, this was because commutative operators may not be 
really commutative when applied to certain user-defined types
or meta-types. Matrix multiplication comes to mind. 

> * new facility to precompile Lua code from inside Lua (function
> stringdump).

This is great. Could there also be a functiondump() function 
by which you can dump the bytecode of an existing lua function?
I'd love to use such a function to write self-modifying lua programs
that can save their own state, to do some "persistent" AI programming. 
Thank you very much.

"No one knows true heroes, for they speak not of their greatness." -- 
Daniel Remar.
Björn De Meyer