diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2011-06-24 11:36:21 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2011-06-24 11:36:21 -0300 |
commit | 29644366fcd2fa41ffe6387982541ac5dae49e8c (patch) | |
tree | 10ce5716b349b30ac900f2c1bf599165c120a35a | |
parent | 6eadedbfa10bcc4a9d7b0694e48686105d86538f (diff) | |
download | lua-29644366fcd2fa41ffe6387982541ac5dae49e8c.tar.gz lua-29644366fcd2fa41ffe6387982541ac5dae49e8c.tar.bz2 lua-29644366fcd2fa41ffe6387982541ac5dae49e8c.zip |
useless assignments removed (macros already do the assignment)
-rw-r--r-- | ltests.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: ltests.c,v 2.118 2011/05/25 14:12:28 roberto Exp roberto $ | 2 | ** $Id: ltests.c,v 2.119 2011/06/02 19:31:40 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 | */ |
@@ -368,7 +368,7 @@ static void checkgraylist (GCObject *l) { | |||
368 | while (l) { | 368 | while (l) { |
369 | lua_assert(isgray(l)); | 369 | lua_assert(isgray(l)); |
370 | lua_assert(!testbit(l->gch.marked, TESTGRAYBIT)); | 370 | lua_assert(!testbit(l->gch.marked, TESTGRAYBIT)); |
371 | l->gch.marked = l_setbit(l->gch.marked, TESTGRAYBIT); | 371 | l_setbit(l->gch.marked, TESTGRAYBIT); |
372 | switch (gch(l)->tt) { | 372 | switch (gch(l)->tt) { |
373 | case LUA_TTABLE: l = gco2t(l)->gclist; break; | 373 | case LUA_TTABLE: l = gco2t(l)->gclist; break; |
374 | case LUA_TFUNCTION: l = gco2cl(l)->c.gclist; break; | 374 | case LUA_TFUNCTION: l = gco2cl(l)->c.gclist; break; |
@@ -405,7 +405,7 @@ static void checkold (global_State *g, GCObject *o) { | |||
405 | else lua_assert(!isold); /* non-old object cannot be after an old one */ | 405 | else lua_assert(!isold); /* non-old object cannot be after an old one */ |
406 | if (isgray(o)) { | 406 | if (isgray(o)) { |
407 | lua_assert(!keepinvariant(g) || testbit(o->gch.marked, TESTGRAYBIT)); | 407 | lua_assert(!keepinvariant(g) || testbit(o->gch.marked, TESTGRAYBIT)); |
408 | o->gch.marked = resetbit(o->gch.marked, TESTGRAYBIT); | 408 | resetbit(o->gch.marked, TESTGRAYBIT); |
409 | } | 409 | } |
410 | lua_assert(!testbit(o->gch.marked, TESTGRAYBIT)); | 410 | lua_assert(!testbit(o->gch.marked, TESTGRAYBIT)); |
411 | } | 411 | } |
@@ -422,7 +422,7 @@ int lua_checkmemory (lua_State *L) { | |||
422 | } | 422 | } |
423 | lua_assert(!isdead(g, gcvalue(&g->l_registry))); | 423 | lua_assert(!isdead(g, gcvalue(&g->l_registry))); |
424 | checkstack(g, g->mainthread); | 424 | checkstack(g, g->mainthread); |
425 | g->mainthread->marked = resetbit(g->mainthread->marked, TESTGRAYBIT); | 425 | resetbit(g->mainthread->marked, TESTGRAYBIT); |
426 | /* check 'allgc' list */ | 426 | /* check 'allgc' list */ |
427 | markgrays(g); | 427 | markgrays(g); |
428 | checkold(g, g->allgc); | 428 | checkold(g, g->allgc); |