Variable sigIntExtension
A function the sigint handler will call (if overridden - which is the
case when [RealTimeConsoleInput] is active on Posix or if you compile with
TerminalDirectToEmulator version on any platform at this time) in addition
to the library's default handling, which is to set a flag for the event loop
to inform you.
nothrow @nogc void delegate() sigIntExtension;
Remember, this is called from a signal handler and/or from a separate thread, so you are not allowed to do much with it and need care when setting TLS variables.
I suggest you only set a __gshared bool flag as many other operations will risk
undefined behavior.
This function is never called on the default Windows console
configuration in the current implementation. You can use
-version=TerminalDirectToEmulator to guarantee it is called there
too by causing the library to pop up a gui window for your application.
History
Added March 30, 2020. Included in release v7.1.0.