MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / traverseproto

Function traverseproto

Source/Misc/lua/src/lua.c:6205–6222  ·  view source on GitHub ↗

** All marks are conditional because a GC may happen while the ** prototype is still being created */

Source from the content-addressed store, hash-verified

6203** prototype is still being created
6204*/
6205static void traverseproto (global_State *g, Proto *f) {
6206int i;
6207if (f->source) stringmark(f->source);
6208for (i=0; i<f->sizek; i++) /* mark literals */
6209markvalue(g, &f->k[i]);
6210for (i=0; i<f->sizeupvalues; i++) { /* mark upvalue names */
6211if (f->upvalues[i])
6212stringmark(f->upvalues[i]);
6213}
6214for (i=0; i<f->sizep; i++) { /* mark nested protos */
6215if (f->p[i])
6216markobject(g, f->p[i]);
6217}
6218for (i=0; i<f->sizelocvars; i++) { /* mark local-variable names */
6219if (f->locvars[i].varname)
6220stringmark(f->locvars[i].varname);
6221}
6222}
6223
6224
6225

Callers 1

propagatemarkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected