Skip to content

Commit a38e484

Browse files
committed
Increase luau max stack size to 1M from 100k
1 parent eed4888 commit a38e484

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

mlua-sys/build/find_vendored.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ pub fn probe_lua() {
2121
#[cfg(feature = "luau")]
2222
let artifacts = luau0_src::Build::new()
2323
.enable_codegen(cfg!(feature = "luau-codegen"))
24+
.set_max_cstack_size(1000000)
2425
.set_vector_size(if cfg!(feature = "luau-vector4") { 4 } else { 3 })
2526
.build();
2627

mlua-sys/src/luau/lua.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use std::{mem, ptr};
88
pub const LUA_MULTRET: c_int = -1;
99

1010
// Max number of Lua stack slots
11-
const LUAI_MAXCSTACK: c_int = 100000;
11+
const LUAI_MAXCSTACK: c_int = 1000000;
1212

1313
//
1414
// Pseudo-indices

0 commit comments

Comments
 (0)