Add import sharedlist when hasThreadSupport
Without this change, a user's Nim code won't compile if they're using both threads & the mark-and-sweep GC:
lib/system/gc_ms.nim(75, 18) Error: undeclared identifier: 'SharedList'
toDispose: SharedList[pointer]
^
This small code block addition was copied from "lib/system/gc.nim" (where it appears directly after a `when defined(memProfiler)` block also).
This commit is contained in:
parent
1446dc87c3
commit
13d06d9a5c
1 changed files with 3 additions and 0 deletions
|
|
@ -28,6 +28,9 @@ template mulThreshold(x): expr {.immediate.} = x * 2
|
||||||
|
|
||||||
when defined(memProfiler):
|
when defined(memProfiler):
|
||||||
proc nimProfile(requestedSize: int)
|
proc nimProfile(requestedSize: int)
|
||||||
|
|
||||||
|
when hasThreadSupport:
|
||||||
|
import sharedlist
|
||||||
|
|
||||||
type
|
type
|
||||||
WalkOp = enum
|
WalkOp = enum
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue