summary refs log tree commit diff stats
path: root/lib/system/gc_common.nim
diff options
context:
space:
mode:
Diffstat (limited to 'lib/system/gc_common.nim')
-rw-r--r--lib/system/gc_common.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/system/gc_common.nim b/lib/system/gc_common.nim
index aec8b67cb..8f9d1edb6 100644
--- a/lib/system/gc_common.nim
+++ b/lib/system/gc_common.nim
@@ -135,7 +135,7 @@ when allowForeignThreadGc:
   var
     localGcInitialized {.rtlThreadVar.}: bool
 
-  proc setupForeignThreadGc*() =
+  proc setupForeignThreadGc*() {.gcsafe.} =
     ## Call this if you registered a callback that will be run from a thread not
     ## under your control. This has a cheap thread-local guard, so the GC for
     ## this thread will only be initialized once per thread, no matter how often