diff options
| author | Benoit Germain <benoit.germain@ubisoft.com> | 2024-12-10 17:42:51 +0100 |
|---|---|---|
| committer | Benoit Germain <benoit.germain@ubisoft.com> | 2024-12-10 17:42:51 +0100 |
| commit | e4543302fcacf871b319710e925919203f520f32 (patch) | |
| tree | f45fcd9c74dbfbbd9106b25e514f25d34e9f478d | |
| parent | d60372303737df9ceb762858d50f6a7de57b46aa (diff) | |
| download | lanes-e4543302fcacf871b319710e925919203f520f32.tar.gz lanes-e4543302fcacf871b319710e925919203f520f32.tar.bz2 lanes-e4543302fcacf871b319710e925919203f520f32.zip | |
deep_test buildfix
| -rw-r--r-- | deep_test/deep_test.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/deep_test/deep_test.cpp b/deep_test/deep_test.cpp index 17c398a..0c7ed0f 100644 --- a/deep_test/deep_test.cpp +++ b/deep_test/deep_test.cpp | |||
| @@ -56,7 +56,7 @@ static int deep_gc(lua_State* const L_) | |||
| 56 | { | 56 | { |
| 57 | MyDeepUserdata* const _self{ static_cast<MyDeepUserdata*>(MyDeepFactory::Instance.toDeep(L_, StackIndex{ 1 })) }; | 57 | MyDeepUserdata* const _self{ static_cast<MyDeepUserdata*>(MyDeepFactory::Instance.toDeep(L_, StackIndex{ 1 })) }; |
| 58 | luaL_argcheck(L_, 1, !_self->inUse.load(), "being collected while in use!"); | 58 | luaL_argcheck(L_, 1, !_self->inUse.load(), "being collected while in use!"); |
| 59 | if (lua_getiuservalue(L_, -1, 1) == LUA_TFUNCTION) { | 59 | if (lua_getiuservalue(L_, kIdxTop, UserValueIndex{ 1 }) == LUA_TFUNCTION) { |
| 60 | lua_call(L_, 0, 0); | 60 | lua_call(L_, 0, 0); |
| 61 | } | 61 | } |
| 62 | return 0; | 62 | return 0; |
| @@ -240,7 +240,7 @@ static int clonable_tostring(lua_State* L) | |||
| 240 | static int clonable_gc(lua_State* const L_) | 240 | static int clonable_gc(lua_State* const L_) |
| 241 | { | 241 | { |
| 242 | MyClonableUserdata* self = static_cast<MyClonableUserdata*>(lua_touserdata(L_, 1)); | 242 | MyClonableUserdata* self = static_cast<MyClonableUserdata*>(lua_touserdata(L_, 1)); |
| 243 | if (lua_getiuservalue(L_, -1, 1) == LUA_TFUNCTION) { | 243 | if (lua_getiuservalue(L_, kIdxTop, UserValueIndex{ 1 }) == LUA_TFUNCTION) { |
| 244 | lua_call(L_, 0, 0); | 244 | lua_call(L_, 0, 0); |
| 245 | } | 245 | } |
| 246 | return 0; | 246 | return 0; |
