lua-users home
lua-l archive

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


My use case is dealing with third-party modules that don't expose an
API to introspect the userdata they create -- I wouldn't want to have
to code something up myself in C to deal with their C.  I might not
have a compiler at my disposal, I wouldn't want to have to recall how
to write this function from memory, wouldn't want to have to consult
the Lua manual first -- I'd like to be able to just use this function
that I know exists from the debug library.  This would be an extremely
simple addition.

If I wanted more direct handling of userdata content later, *then* I
would like to turn to C.  This would be a simple function help
inefficiently prototype unpacking a userdata without jumping directly
to C.

I thought this went in the same vein as having pack(int|float).
Furthermore, "people" are much more likely to use and trust your .lua
than they are to go through the effort of pulling in your .c/.so with
a package manager or building it from source -- it would be nice to
have this simple functionality upstream.