We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7001537 commit 2ec0e85Copy full SHA for 2ec0e85
src/libstd/thread/mod.rs
@@ -607,7 +607,7 @@ impl Builder {
607
pub fn spawn<F, T>(f: F) -> JoinHandle<T> where
608
F: FnOnce() -> T, F: Send + 'static, T: Send + 'static
609
{
610
- Builder::new().spawn(f).unwrap()
+ Builder::new().spawn(f).expect("failed to spawn thread")
611
}
612
613
/// Gets a handle to the thread that invokes it.
0 commit comments