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
use mlua::prelude::*;fnmain(){mlua_issue_491().unwrap();}fnmlua_issue_491() -> LuaResult<()>{let lua = Lua::new();let pair_of_tables = (lua.create_table()?, lua.create_table()?);
lua.create_function(move |_lua,()| {
_ = &pair_of_tables;Ok(())})?;for i in0..10000{println!("{i}");
lua.create_table()?;}Ok(())}
mlua 0.10.1 with features lua54 and vendored
rustc 1.82.0 (f6e511eec 2024-10-15)
Apple M2 Max running macOS Sequoia 15.1.1
On my machine, this produces the following output deterministically when run in debug mode:
...
323
324
Assertion failed: (((!(((((((to))->tt_)) & 0x0F)) == (0)) || to != &(L->l_G)->nilvalue)) && "invalid index"), function lua_copy, file lapi.c, line 260.
fish: Job 1, 'cargo run' terminated by signal SIGABRT (Abort)
This bug also occurs with lua53, lua52, and lua51, although the last number printed varies (still well below 1000).
I'm unable to reproduce this in release mode.
I found this because it happens around 5% of the time that I launch Hyperspeedcube 2. In that case, the closure is capturing a (Lua, LuaTable) instead of (LuaTable, LuaTable).
The text was updated successfully, but these errors were encountered:
Steps to reproduce
lua54
andvendored
On my machine, this produces the following output deterministically when run in debug mode:
This bug also occurs with
lua53
,lua52
, andlua51
, although the last number printed varies (still well below 1000).I'm unable to reproduce this in release mode.
I found this because it happens around 5% of the time that I launch Hyperspeedcube 2. In that case, the closure is capturing a
(Lua, LuaTable)
instead of(LuaTable, LuaTable)
.The text was updated successfully, but these errors were encountered: