Function rustc_driver::install_ice_hook
source · pub fn install_ice_hook(
bug_report_url: &'static str,
extra_info: fn(_: &Handler)
)
Expand description
Installs a panic hook that will print the ICE message on unexpected panics.
The hook is intended to be useable even by external tools. You can pass a custom
bug_report_url
, or report arbitrary info in extra_info
. Note that extra_info
is called in
a context where the thread is currently panicking, so it must not panic or the process will
abort.
If you have no extra info to report, pass the empty closure |_| ()
as the argument to
extra_info.
A custom rustc driver can skip calling this to set up a custom ICE hook.