]> git.lizzy.rs Git - rust.git/commitdiff
Fix integers in tests (fixup #22700)
authorManish Goregaokar <manishsmail@gmail.com>
Tue, 24 Feb 2015 08:19:01 +0000 (13:49 +0530)
committerManish Goregaokar <manishsmail@gmail.com>
Tue, 24 Feb 2015 08:19:01 +0000 (13:49 +0530)
src/libstd/sync/mpsc/select.rs
src/libstd/sync/rwlock.rs
src/libstd/sync/task_pool.rs

index b6f93b8e0e574ce470608e2e70b6960c36ecb357..8de5bbc6206658c10d740bc67974e19edb00434f 100644 (file)
@@ -473,7 +473,7 @@ fn both_ready() {
 
     #[test]
     fn stress() {
-        static AMT: u32 = 10000;
+        static AMT: i32 = 10000;
         let (tx1, rx1) = channel::<i32>();
         let (tx2, rx2) = channel::<i32>();
         let (tx3, rx3) = channel::<()>();
index 495a172e2453d4fc5539cf9d905658d1f7c5bf58..6fd2a6ed77d264c754e19e5ae46873ce274cb117 100644 (file)
@@ -425,8 +425,8 @@ fn static_smoke() {
     #[test]
     fn frob() {
         static R: StaticRwLock = RW_LOCK_INIT;
-        static N: u32 = 10;
-        static M: u32 = 1000;
+        static N: usize = 10;
+        static M: usize = 1000;
 
         let (tx, rx) = channel::<()>();
         for _ in 0..N {
index 738aeccbe7aab1488f001aec3e9838b3f203f9ba..31f3dfd877cfb682f6e2208d30dc6f48f27ec0ad 100644 (file)
@@ -142,7 +142,7 @@ mod test {
     use super::*;
     use sync::mpsc::channel;
 
-    const TEST_TASKS: u32 = 4;
+    const TEST_TASKS: usize = 4;
 
     #[test]
     fn test_works() {