God knows what's modified
This commit is contained in:
@@ -9,14 +9,14 @@
|
||||
// if globalname is already present, and not a table, error.
|
||||
// if globalname is not present, create and initialize it.
|
||||
//
|
||||
LuaDefineGlobalFunction(globaldb_global) {
|
||||
LuaDefine(globaldb_global, "f") {
|
||||
LuaArg globalname;
|
||||
LuaRet globaltab;
|
||||
LuaVar globaldb;
|
||||
LuaStack LS(L, globalname, globaltab, globaldb);
|
||||
|
||||
LS.checktype(globalname, LUA_TSTRING);
|
||||
|
||||
LS.checkstring(globalname);
|
||||
|
||||
// Get a pointer to the globaldb.
|
||||
LS.getfield(globaldb, LuaRegistry, "globaldb");
|
||||
if (!LS.istable(globaldb)) {
|
||||
@@ -29,7 +29,7 @@ LuaDefineGlobalFunction(globaldb_global) {
|
||||
if (LS.istable(globaltab)) {
|
||||
return LS.result();
|
||||
} else if (!LS.isnil(globaltab)) {
|
||||
luaL_error(L, "%s is not a global", LS.tostring(globalname).c_str());
|
||||
luaL_error(L, "%s is not a global", LS.ckstring(globalname).c_str());
|
||||
}
|
||||
|
||||
// Create a new globaltab and store it in the globaldb.
|
||||
|
||||
Reference in New Issue
Block a user