diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-10-25 09:50:46 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-10-25 09:50:46 -0200 |
commit | bdf566a8a32450c2eb6273c8c1a92e2181b6846e (patch) | |
tree | b301da541fbad81034216a6e0465cc381082431e /lgc.c | |
parent | c3c78030f79fdbbb06265d50645e408d60e7798e (diff) | |
download | lua-bdf566a8a32450c2eb6273c8c1a92e2181b6846e.tar.gz lua-bdf566a8a32450c2eb6273c8c1a92e2181b6846e.tar.bz2 lua-bdf566a8a32450c2eb6273c8c1a92e2181b6846e.zip |
`name' in comments changed to 'name'
Diffstat (limited to 'lgc.c')
-rw-r--r-- | lgc.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.c,v 2.195 2014/09/04 18:15:29 roberto Exp roberto $ | 2 | ** $Id: lgc.c,v 2.196 2014/10/03 12:54:37 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 | */ |
@@ -119,14 +119,14 @@ static void removeentry (Node *n) { | |||
119 | /* | 119 | /* |
120 | ** tells whether a key or value can be cleared from a weak | 120 | ** tells whether a key or value can be cleared from a weak |
121 | ** table. Non-collectable objects are never removed from weak | 121 | ** table. Non-collectable objects are never removed from weak |
122 | ** tables. Strings behave as `values', so are never removed too. for | 122 | ** tables. Strings behave as 'values', so are never removed too. for |
123 | ** other objects: if really collected, cannot keep them; for objects | 123 | ** other objects: if really collected, cannot keep them; for objects |
124 | ** being finalized, keep them in keys, but not in values | 124 | ** being finalized, keep them in keys, but not in values |
125 | */ | 125 | */ |
126 | static int iscleared (global_State *g, const TValue *o) { | 126 | static int iscleared (global_State *g, const TValue *o) { |
127 | if (!iscollectable(o)) return 0; | 127 | if (!iscollectable(o)) return 0; |
128 | else if (ttisstring(o)) { | 128 | else if (ttisstring(o)) { |
129 | markobject(g, tsvalue(o)); /* strings are `values', so are never weak */ | 129 | markobject(g, tsvalue(o)); /* strings are 'values', so are never weak */ |
130 | return 0; | 130 | return 0; |
131 | } | 131 | } |
132 | else return iswhite(gcvalue(o)); | 132 | else return iswhite(gcvalue(o)); |
@@ -1031,7 +1031,7 @@ static lu_mem singlestep (lua_State *L) { | |||
1031 | g->GCmemtrav = 0; | 1031 | g->GCmemtrav = 0; |
1032 | lua_assert(g->gray); | 1032 | lua_assert(g->gray); |
1033 | propagatemark(g); | 1033 | propagatemark(g); |
1034 | if (g->gray == NULL) /* no more `gray' objects? */ | 1034 | if (g->gray == NULL) /* no more gray objects? */ |
1035 | g->gcstate = GCSatomic; /* finish propagate phase */ | 1035 | g->gcstate = GCSatomic; /* finish propagate phase */ |
1036 | return g->GCmemtrav; /* memory traversed in this step */ | 1036 | return g->GCmemtrav; /* memory traversed in this step */ |
1037 | } | 1037 | } |