Workaround gc crash on Windows

This commit is contained in:
Ganesh Viswanathan 2019-01-30 11:52:13 -06:00
commit 13981e1997
2 changed files with 6 additions and 2 deletions

View file

@ -1,5 +1,6 @@
#[
see D20190127T231316 workaround for fact that toast needs to build scanner.cc, which would otherwise result in link erros such as:
see D20190127T231316 workaround for fact that toast needs to build
scanner.cc, which would otherwise result in link errors such as:
"std::terminate()", referenced from:
___clang_call_terminate in scanner.cc.o
]#
@ -7,3 +8,7 @@ when defined(MacOSX):
switch("clang.linkerexe", "g++")
else:
switch("gcc.linkerexe", "g++")
# Workaround for NilAccessError crash on Windows
when defined(Windows):
switch("gc", "markAndSweep")

View file

@ -76,5 +76,4 @@ template defineEnum*(typ: untyped) =
proc `mod`*(x: int, y: typ): typ {.borrow.}
proc `mod`*(x, y: typ): typ {.borrow.}
proc `$` *(x: typ): string {.borrow.}