Skip to main content

isobjcleared

Function isobjcleared 

Source
pub unsafe fn isobjcleared(o: *mut GCObject) -> i32
Expand description

Returns non-zero if the GC object o has been cleared (collected).

Strings are treated as values and are never considered cleared: their white bits are reset so they will not be swept, and 0 is returned immediately. For all other collectable types the function returns the iswhite result — non-zero means the object’s white bits are still set, i.e. it was not reached during the mark phase and has been (or will be) collected.

C++ original: static int isobjcleared(GCObject* o) in VM/src/lgc.cpp:608