String buffers, part 2d: basic string buffer methods.
Sponsored by fmad.io.
This commit is contained in:
@@ -65,6 +65,12 @@ static void gc_mark(global_State *g, GCobj *o)
|
||||
gray2black(o); /* Userdata are never gray. */
|
||||
if (mt) gc_markobj(g, mt);
|
||||
gc_markobj(g, tabref(gco2ud(o)->env));
|
||||
if (LJ_HASBUFFER && gco2ud(o)->udtype == UDTYPE_BUFFER) {
|
||||
SBufExt *sbx = (SBufExt *)uddata(gco2ud(o));
|
||||
if (sbufiscow(sbx) && gcref(sbx->cowref) != NULL) {
|
||||
gc_markobj(g, gcref(sbx->cowref));
|
||||
}
|
||||
}
|
||||
} else if (LJ_UNLIKELY(gct == ~LJ_TUPVAL)) {
|
||||
GCupval *uv = gco2uv(o);
|
||||
gc_marktv(g, uvval(uv));
|
||||
|
||||
Reference in New Issue
Block a user