summaryrefslogtreecommitdiff
path: root/ltests.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2001-01-19 11:20:30 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2001-01-19 11:20:30 -0200
commit4ac58853dc820127a11a14ed8bde1fae9458369e (patch)
treee8179692c97e935ba921c8ebd17abf9c8510d89e /ltests.c
parentf2c451d7455aad3496f32dfa2bfca7f7e8b5376d (diff)
downloadlua-4ac58853dc820127a11a14ed8bde1fae9458369e.tar.gz
lua-4ac58853dc820127a11a14ed8bde1fae9458369e.tar.bz2
lua-4ac58853dc820127a11a14ed8bde1fae9458369e.zip
thead-specific state separated from "global" state
Diffstat (limited to 'ltests.c')
-rw-r--r--ltests.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ltests.c b/ltests.c
index b767e2ca..dbfdd7ca 100644
--- a/ltests.c
+++ b/ltests.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltests.c,v 1.56 2001/01/15 16:13:24 roberto Exp roberto $ 2** $Id: ltests.c,v 1.57 2001/01/18 15:59:09 roberto Exp roberto $
3** Internal Module for Debugging of the Lua Implementation 3** Internal Module for Debugging of the Lua Implementation
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -215,7 +215,8 @@ static int table_query (lua_State *L) {
215 215
216 216
217static int string_query (lua_State *L) { 217static int string_query (lua_State *L) {
218 stringtable *tb = (*luaL_check_string(L, 1) == 's') ? &L->strt : &L->udt; 218 stringtable *tb = (*luaL_check_string(L, 1) == 's') ? &G(L)->strt :
219 &G(L)->udt;
219 int s = luaL_opt_int(L, 2, 0) - 1; 220 int s = luaL_opt_int(L, 2, 0) - 1;
220 if (s==-1) { 221 if (s==-1) {
221 lua_pushnumber(L ,tb->nuse); 222 lua_pushnumber(L ,tb->nuse);