--gc:v2 requires global root tracking

This commit is contained in:
Araq
2015-11-29 14:56:30 +01:00
parent a1739455d3
commit 6361f6b76d

View File

@@ -16,7 +16,7 @@ const
# above X strings a hash-switch for strings is generated
proc registerGcRoot(p: BProc, v: PSym) =
if gSelectedGC in {gcMarkAndSweep, gcGenerational} and
if gSelectedGC in {gcMarkAndSweep, gcGenerational, gcV2} and
containsGarbageCollectedRef(v.loc.t):
# we register a specialized marked proc here; this has the advantage
# that it works out of the box for thread local storage then :-)