pub async fn ctrl_c() -> Result<()>Expand description
Completes once the process gets a Ctrl-C: SIGINT on unix, the
console’s CTRL_C_EVENT on Windows. Listening starts with the first
poll; on unix the default action of SIGINT (ending the process) is
replaced for good from then on.
§Errors
When the handler cannot be installed.