diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-07-19 12:14:46 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-07-19 12:14:46 -0300 |
commit | 3c6d0aaa7d07de2cf24d09195b6678abbfee2268 (patch) | |
tree | 92e7da72cd89505e8d1326b71593df9b1e7b0fdf /ltests.c | |
parent | e43612aaf62bbb92fd7555b132d9ee1c0394dc58 (diff) | |
download | lua-3c6d0aaa7d07de2cf24d09195b6678abbfee2268.tar.gz lua-3c6d0aaa7d07de2cf24d09195b6678abbfee2268.tar.bz2 lua-3c6d0aaa7d07de2cf24d09195b6678abbfee2268.zip |
'iswhite' and related macros now can work directly on any object
(no need to convert to 'GCObject')
Diffstat (limited to 'ltests.c')
-rw-r--r-- | ltests.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: ltests.c,v 2.179 2014/07/18 13:36:14 roberto Exp roberto $ | 2 | ** $Id: ltests.c,v 2.180 2014/07/18 14:46:47 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 | */ |
@@ -294,7 +294,7 @@ static void checkstack (global_State *g, lua_State *L1) { | |||
294 | StkId o; | 294 | StkId o; |
295 | CallInfo *ci; | 295 | CallInfo *ci; |
296 | UpVal *uv; | 296 | UpVal *uv; |
297 | lua_assert(!isdead(g, obj2gco(L1))); | 297 | lua_assert(!isdead(g, L1)); |
298 | for (uv = L1->openupval; uv != NULL; uv = uv->u.open.next) | 298 | for (uv = L1->openupval; uv != NULL; uv = uv->u.open.next) |
299 | lua_assert(upisopen(uv)); /* must be open */ | 299 | lua_assert(upisopen(uv)); /* must be open */ |
300 | for (ci = L1->ci; ci != NULL; ci = ci->previous) { | 300 | for (ci = L1->ci; ci != NULL; ci = ci->previous) { |
@@ -404,7 +404,7 @@ int lua_checkmemory (lua_State *L) { | |||
404 | GCObject *o; | 404 | GCObject *o; |
405 | int maybedead; | 405 | int maybedead; |
406 | if (keepinvariant(g)) { | 406 | if (keepinvariant(g)) { |
407 | lua_assert(!iswhite(obj2gco(g->mainthread))); | 407 | lua_assert(!iswhite(g->mainthread)); |
408 | lua_assert(!iswhite(gcvalue(&g->l_registry))); | 408 | lua_assert(!iswhite(gcvalue(&g->l_registry))); |
409 | } | 409 | } |
410 | lua_assert(!isdead(g, gcvalue(&g->l_registry))); | 410 | lua_assert(!isdead(g, gcvalue(&g->l_registry))); |