diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2001-01-29 17:34:02 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2001-01-29 17:34:02 -0200 |
commit | 63a822c8e199918c54e325cbc8696ed04071aba8 (patch) | |
tree | 430e1b2fe1ffafb712bd712b5b625a18afaa953d /lgc.c | |
parent | 09def5da4440a5a91c2721f495bd9c3df1081874 (diff) | |
download | lua-63a822c8e199918c54e325cbc8696ed04071aba8.tar.gz lua-63a822c8e199918c54e325cbc8696ed04071aba8.tar.bz2 lua-63a822c8e199918c54e325cbc8696ed04071aba8.zip |
all boxed types start with their tags
Diffstat (limited to 'lgc.c')
-rw-r--r-- | lgc.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.c,v 1.81 2001/01/26 14:16:24 roberto Exp roberto $ | 2 | ** $Id: lgc.c,v 1.82 2001/01/29 17:16:58 roberto Exp roberto $ |
3 | ** Garbage Collector | 3 | ** Garbage Collector |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -66,6 +66,8 @@ static void marktable (GCState *st, Hash *h) { | |||
66 | 66 | ||
67 | 67 | ||
68 | static void markobject (GCState *st, TObject *o) { | 68 | static void markobject (GCState *st, TObject *o) { |
69 | lua_assert(ttype(o) == LUA_TNUMBER || | ||
70 | ttype(o) == ((TValue *)(o->value.v))->ttype); | ||
69 | switch (ttype(o)) { | 71 | switch (ttype(o)) { |
70 | case LUA_TUSERDATA: case LUA_TSTRING: | 72 | case LUA_TUSERDATA: case LUA_TSTRING: |
71 | strmark(tsvalue(o)); | 73 | strmark(tsvalue(o)); |