attempt to fix tunidecode test; GC cares for seq->openArray conversions
This commit is contained in:
parent
04e5c6718e
commit
c8dda8cc6f
5 changed files with 982 additions and 947 deletions
|
|
@ -517,6 +517,12 @@ proc gcMark(gch: var TGcHeap, p: pointer) {.inline.} =
|
|||
# mark the cell:
|
||||
cell.refcount = cell.refcount +% rcIncrement
|
||||
add(gch.decStack, cell)
|
||||
# care for string->cstring and seq->openArray conversions:
|
||||
var b = cast[PCell](c -% sizeof(TGenericSeq))
|
||||
if isAllocatedPtr(gch.region, b):
|
||||
# mark the cell:
|
||||
b.refcount = b.refcount +% rcIncrement
|
||||
add(gch.decStack, b)
|
||||
|
||||
proc markThreadStacks(gch: var TGcHeap) =
|
||||
when hasThreadSupport and hasSharedHeap:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue