about summary refs log tree commit diff
path: root/src/libstd/sys/wasm/thread.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/sys/wasm/thread.rs')
-rw-r--r--src/libstd/sys/wasm/thread.rs16
1 files changed, 3 insertions, 13 deletions
diff --git a/src/libstd/sys/wasm/thread.rs b/src/libstd/sys/wasm/thread.rs
index f9abb0b825a..c2322088e8e 100644
--- a/src/libstd/sys/wasm/thread.rs
+++ b/src/libstd/sys/wasm/thread.rs
@@ -1,13 +1,3 @@
-// Copyright 2017 The Rust Project Developers. See the COPYRIGHT
-// file at the top-level directory of this distribution and at
-// http://rust-lang.org/COPYRIGHT.
-//
-// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
-// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
-// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
-// option. This file may not be copied, modified, or distributed
-// except according to those terms.
-
 use boxed::FnBox;
 use ffi::CStr;
 use io;
@@ -41,7 +31,7 @@ impl Thread {
 
     #[cfg(target_feature = "atomics")]
     pub fn sleep(dur: Duration) {
-        use arch::wasm32::atomic;
+        use arch::wasm32;
         use cmp;
 
         // Use an atomic wait to block the current thread artificially with a
@@ -53,7 +43,7 @@ impl Thread {
         while nanos > 0 {
             let amt = cmp::min(i64::max_value() as u128, nanos);
             let mut x = 0;
-            let val = unsafe { atomic::wait_i32(&mut x, 0, amt as i64) };
+            let val = unsafe { wasm32::i32_atomic_wait(&mut x, 0, amt as i64) };
             debug_assert_eq!(val, 2);
             nanos -= amt;
         }
@@ -107,7 +97,7 @@ cfg_if! {
             panic!("thread local data not implemented on wasm with atomics yet")
         }
 
-        pub fn tcb_set(ptr: *mut u8) {
+        pub fn tcb_set(_ptr: *mut u8) {
             panic!("thread local data not implemented on wasm with atomics yet")
         }
     } else {