about summary refs log tree commit diff
path: root/src/libstd/thread
diff options
context:
space:
mode:
authorFlorian Hahn <flo@fhahn.com>2015-12-18 13:29:49 +0100
committerFlorian Hahn <flo@fhahn.com>2015-12-29 16:07:01 +0100
commite27cbeff370897b8450caa204c08049651a10c13 (patch)
tree471ed007f694634c94b22bfcc5ff4aa2bcc8be16 /src/libstd/thread
parent27a1834ce522e3ec7fe4726b1661de16ee30c503 (diff)
downloadrust-e27cbeff370897b8450caa204c08049651a10c13.tar.gz
rust-e27cbeff370897b8450caa204c08049651a10c13.zip
Fix warnings when compiling stdlib with --test
Diffstat (limited to 'src/libstd/thread')
-rw-r--r--src/libstd/thread/mod.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libstd/thread/mod.rs b/src/libstd/thread/mod.rs
index 0e525f39421..116cd5da2ce 100644
--- a/src/libstd/thread/mod.rs
+++ b/src/libstd/thread/mod.rs
@@ -830,14 +830,14 @@ mod tests {
     fn test_park_timeout_unpark_before() {
         for _ in 0..10 {
             thread::current().unpark();
-            thread::park_timeout_ms(u32::MAX);
+            thread::park_timeout(Duration::from_millis(u32::MAX as u64));
         }
     }
 
     #[test]
     fn test_park_timeout_unpark_not_called() {
         for _ in 0..10 {
-            thread::park_timeout_ms(10);
+            thread::park_timeout(Duration::from_millis(10));
         }
     }
 
@@ -847,17 +847,17 @@ mod tests {
             let th = thread::current();
 
             let _guard = thread::spawn(move || {
-                super::sleep_ms(50);
+                super::sleep(Duration::from_millis(50));
                 th.unpark();
             });
 
-            thread::park_timeout_ms(u32::MAX);
+            thread::park_timeout(Duration::from_millis(u32::MAX as u64));
         }
     }
 
     #[test]
     fn sleep_ms_smoke() {
-        thread::sleep_ms(2);
+        thread::sleep(Duration::from_millis(2));
     }
 
     // NOTE: the corresponding test for stderr is in run-pass/thread-stderr, due