diff options
Diffstat (limited to 'src/state.cpp')
-rw-r--r-- | src/state.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/state.cpp b/src/state.cpp index a6c9859..e258f9e 100644 --- a/src/state.cpp +++ b/src/state.cpp | |||
@@ -67,12 +67,12 @@ THE SOFTWARE. | |||
67 | 67 | ||
68 | _U->requireMutex.lock(); | 68 | _U->requireMutex.lock(); |
69 | // starting with Lua 5.4, require may return a second optional value, so we need LUA_MULTRET | 69 | // starting with Lua 5.4, require may return a second optional value, so we need LUA_MULTRET |
70 | int _rc{ lua_pcall(L_, _args, LUA_MULTRET, 0 /*errfunc*/) }; // L_: err|result(s) | 70 | LuaError const _rc{ lua_pcall(L_, _args, LUA_MULTRET, 0 /*errfunc*/) }; // L_: err|result(s) |
71 | _U->requireMutex.unlock(); | 71 | _U->requireMutex.unlock(); |
72 | 72 | ||
73 | // the required module (or an error message) is left on the stack as returned value by original require function | 73 | // the required module (or an error message) is left on the stack as returned value by original require function |
74 | 74 | ||
75 | if (_rc != LUA_OK) { // LUA_ERRRUN / LUA_ERRMEM ? | 75 | if (_rc != LuaError::OK) { // LUA_ERRRUN / LUA_ERRMEM ? |
76 | raise_lua_error(L_); | 76 | raise_lua_error(L_); |
77 | } | 77 | } |
78 | // should be 1 for Lua <= 5.3, 1 or 2 starting with Lua 5.4 | 78 | // should be 1 for Lua <= 5.3, 1 or 2 starting with Lua 5.4 |