You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working with MAME (I have to go through the Lua interface) and I want to make my life a little bit easier when working with MAME values. What's the proper way to represent them?
@khvzak I can't get a minimal reproduction to you for a while (it involves me setting some time aside to write C), but the question in the title is more important. If LuaAnyUserData is the wrong type for holding non-Rust userdata, then the problem is with me, not mlua. However, I got the impression from jumping around mlua's source code that LuaAnyUserDatareally means "any userdata from this same dylib" (which means loading up a mlua library in any environment that adds its own userdata & trying to pass that userdata around should crash).
Activity
s5bug commentedon Jan 15, 2026
It's definitely not with
LuaAnyUserData: this causes MAME to segfault, despiteLuaValue::type_namereportinguserdata.khvzak commentedon Jan 22, 2026
Do you have a full code?
s5bug commentedon Jan 22, 2026
@khvzak I can't get a minimal reproduction to you for a while (it involves me setting some time aside to write C), but the question in the title is more important. If
LuaAnyUserDatais the wrong type for holding non-Rust userdata, then the problem is with me, not mlua. However, I got the impression from jumping around mlua's source code thatLuaAnyUserDatareally means "any userdata from this same dylib" (which means loading up a mlua library in any environment that adds its own userdata & trying to pass that userdata around should crash).