lua-users home
lua-l archive

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



> Is it possible to use userdata as an index into a lookup table.

Yes. Any Lua object can be used as a table index, except for nil and, if using numbers conforming to IEEE-754 arithmetic, NaN.

>  While the documentation doesn't seem to explicitly forbid this, I can't get it to work...

Could you possibly be more specific about the problem?