lua-users home
lua-l archive

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


Been doing some experimenting with the Lua 5.2 source and doing a lot of patches mostly for learning purposes, both for understanding Lua internals and brushing up on my seriously rusty C skills. One idea might have some use for some readers--it adds a function "rawstring" to the core which returns the default tostring representation of an object without invoking any metamethods. I use it in __tostring metamethods to get the original representation (in my case, for extracting the address for use as an id number) without creating an infinite loop.

I'm now testing this, and if there is interest, I will make sure my code conforms to power patch guidelines and submit it in a couple of days.

-- Mike Nelson