Hello everyone!
I am trying to use Nim's try / raise / except in a shared library, but it crashes.
My hunch is that I must initialize it somehow. Is there a manual way to initialize it?
Thanks!
You should call NimMain(), which will initialize the GC (yes, --gc:none's seq/string still uses the GC, even if the GC doesn't collect).
Alternatively you can use --gc:arc or --gc:orc instead.
That was what I assumed, thanks!
For others that eventually might be having the same problem, I ended up wrapping C's setjmp and longjmp to implement a very basic custom try / except behavior.