diff options
author | chai <chaifix@163.com> | 2019-03-16 13:03:50 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2019-03-16 13:03:50 +0800 |
commit | 1ab2501db0f9e14f138292880e37120e7a6184de (patch) | |
tree | 2d1cfa82a9a6a3a0f16e516f100b2acb6f7e0e4e /Source/3rdParty/Luax/luax_context.cpp | |
parent | 95d27af75eb2aff8020e073eff8dfeb074b5bba6 (diff) |
*luax
Diffstat (limited to 'Source/3rdParty/Luax/luax_context.cpp')
-rw-r--r-- | Source/3rdParty/Luax/luax_context.cpp | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/Source/3rdParty/Luax/luax_context.cpp b/Source/3rdParty/Luax/luax_context.cpp index c0fb2f5..d41c24f 100644 --- a/Source/3rdParty/Luax/luax_context.cpp +++ b/Source/3rdParty/Luax/luax_context.cpp @@ -3,34 +3,27 @@ namespace Luax { - // ˴˺ - int l_Errfunc(lua_State* L) - { - cc8* err = lua_tostring(L, lua_upvalueindex(1)); - return luaL_error(L, err); - } - - Context::Context(lua_State* L) + LuaxContext::LuaxContext(lua_State* L) : state(L) { assert(state); } - Context::~Context() + LuaxContext::~LuaxContext() { } // ʼcontext - void Context::Setup() + void LuaxContext::Setup() { SetupRefTables(); } - void Context::SetupRefTables() + void LuaxContext::SetupRefTables() { // strong ref weak ref - strongRefTable.Init(state, "LUAX_STRONGREF_TABLE"); - weakRefTable.Init(state, "LUAX_WEAKREF_TABLE", "v"); + strongRefTable.Init(state, "_LUAX_STRONGREF_TABLE"); + weakRefTable.Init(state, "_LUAX_WEAKREF_TABLE", "v"); } }
\ No newline at end of file |