]> git.proxmox.com Git - rustc.git/blobdiff - src/test/run-pass/panic-in-dtor-drops-fields.rs
New upstream version 1.19.0+dfsg1
[rustc.git] / src / test / run-pass / panic-in-dtor-drops-fields.rs
index 3cc01b967ce6af5d452cc6edad560502e25d7372..c5f92fbd55aadc851bbbdd3bef0c628dcc7d5b43 100644 (file)
@@ -8,7 +8,9 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use std::thread::Thread;
+// ignore-emscripten no threads support
+
+use std::thread;
 
 static mut dropped: bool = false;
 
@@ -17,7 +19,7 @@ struct A {
 }
 
 struct B {
-    foo: int,
+    foo: isize,
 }
 
 impl Drop for A {
@@ -33,7 +35,7 @@ impl Drop for B {
 }
 
 pub fn main() {
-    let ret = Thread::scoped(move|| {
+    let ret = thread::spawn(move|| {
         let _a = A { b: B { foo: 3 } };
     }).join();
     assert!(ret.is_err());