Simulate the arrival of the given signal in the main thread,
where the corresponding signal handler will be executed.
If *signum* is omitted, SIGINT is assumed.
A subthread can use this function to interrupt the main thread.
Note: the default signal handler for SIGINT raises ``KeyboardInterrupt``.