Fix exception specifiers

Per
https://status-im.github.io/nim-style-guide/interop.c.html#functions-and-types,
imported functions must be annotated with exception information.

If this is not done, Nim assumes the worst case that the function
potentially could raise an exception which breaks compile-time exception
safety analysis.
This commit is contained in:
Jacek Sieka 2024-02-27 10:16:51 +01:00
parent f75bbc3831
commit a132814448
No known key found for this signature in database
GPG Key ID: A1B09461ABB656B8
1 changed files with 3 additions and 0 deletions

View File

@ -1,3 +1,6 @@
# go functions do not raise nim exceptions and do not interact with the Nim gc
{.push raises: [], gcsafe.}
type SignalCallback* = proc(signal: cstring): void {.cdecl.}
# All procs start with lowercase because the compiler will also need to import