Rewrite Luau require function to support module loaders.

Also add `package` library with `path`/`loaded`/`loaders`.
This commit is contained in:
Alex Orlenko
2023-11-16 14:11:24 +00:00
parent 34476ebf53
commit 2d775695ef
4 changed files with 145 additions and 53 deletions
+1 -1
View File
@@ -438,7 +438,7 @@ impl Lua {
}
#[cfg(feature = "luau")]
mlua_expect!(lua.prepare_luau_state(), "Error preparing Luau state");
mlua_expect!(lua.prepare_luau_state(), "Error configuring Luau");
lua
}