about summary refs log tree commit diff
path: root/src/libstd/panic.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/panic.rs')
-rw-r--r--src/libstd/panic.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/panic.rs b/src/libstd/panic.rs
index 56d638d9df3..aff11d036f8 100644
--- a/src/libstd/panic.rs
+++ b/src/libstd/panic.rs
@@ -29,7 +29,7 @@ pub use panicking::{take_hook, set_hook, PanicInfo, Location};
 #[rustc_deprecated(since = "1.9.0", reason = "renamed to set_hook")]
 #[unstable(feature = "panic_handler", reason = "awaiting feedback", issue = "30449")]
 pub fn set_handler<F>(handler: F) where F: Fn(&PanicInfo) + 'static + Sync + Send {
-    set_hook(handler)
+    set_hook(Box::new(handler))
 }
 
 ///