diff options
| author | Tobias Bucher <tobiasbucher5991@gmail.com> | 2015-01-31 17:23:42 +0100 |
|---|---|---|
| committer | Tobias Bucher <tobiasbucher5991@gmail.com> | 2015-01-31 17:40:40 +0100 |
| commit | b4a43f3864e394959a7d3c3efae6da85bdc59c71 (patch) | |
| tree | 90ce64d37d1e616c4916281f5e1eb338d54ff7a0 /src/libcoretest | |
| parent | 105bfd30012a7d4278117e973b56c170a59fc20d (diff) | |
| download | rust-b4a43f3864e394959a7d3c3efae6da85bdc59c71.tar.gz rust-b4a43f3864e394959a7d3c3efae6da85bdc59c71.zip | |
Kill more `isize`s
Diffstat (limited to 'src/libcoretest')
| -rw-r--r-- | src/libcoretest/hash/mod.rs | 8 | ||||
| -rw-r--r-- | src/libcoretest/iter.rs | 4 | ||||
| -rw-r--r-- | src/libcoretest/option.rs | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/src/libcoretest/hash/mod.rs b/src/libcoretest/hash/mod.rs index ae23024cf20..07f3ab4a5a7 100644 --- a/src/libcoretest/hash/mod.rs +++ b/src/libcoretest/hash/mod.rs @@ -50,13 +50,13 @@ fn test_writer_hasher() { assert_eq!(hash(&5u16), 5); assert_eq!(hash(&5u32), 5); assert_eq!(hash(&5u64), 5); - assert_eq!(hash(&5u), 5); + assert_eq!(hash(&5us), 5); assert_eq!(hash(&5i8), 5); assert_eq!(hash(&5i16), 5); assert_eq!(hash(&5i32), 5); assert_eq!(hash(&5i64), 5); - assert_eq!(hash(&5), 5); + assert_eq!(hash(&5is), 5); assert_eq!(hash(&false), 0); assert_eq!(hash(&true), 1); @@ -76,12 +76,12 @@ fn test_writer_hasher() { // FIXME (#18248) Add tests for hashing Rc<str> and Rc<[T]> unsafe { - let ptr: *const i32 = mem::transmute(5is); + let ptr: *const i32 = mem::transmute(5us); assert_eq!(hash(&ptr), 5); } unsafe { - let ptr: *mut i32 = mem::transmute(5is); + let ptr: *mut i32 = mem::transmute(5us); assert_eq!(hash(&ptr), 5); } } diff --git a/src/libcoretest/iter.rs b/src/libcoretest/iter.rs index 3102abb660f..c9cdf50fdbd 100644 --- a/src/libcoretest/iter.rs +++ b/src/libcoretest/iter.rs @@ -375,7 +375,7 @@ fn test_iterator_size_hint() { assert_eq!(c.clone().enumerate().size_hint(), (uint::MAX, None)); assert_eq!(c.clone().chain(vi.clone().map(|&i| i)).size_hint(), (uint::MAX, None)); assert_eq!(c.clone().zip(vi.clone()).size_hint(), (10, Some(10))); - assert_eq!(c.clone().scan(0i, |_,_| Some(0)).size_hint(), (0, None)); + assert_eq!(c.clone().scan(0, |_,_| Some(0)).size_hint(), (0, None)); assert_eq!(c.clone().filter(|_| false).size_hint(), (0, None)); assert_eq!(c.clone().map(|_| 0).size_hint(), (uint::MAX, None)); assert_eq!(c.filter_map(|_| Some(0)).size_hint(), (0, None)); @@ -389,7 +389,7 @@ fn test_iterator_size_hint() { assert_eq!(vi.clone().enumerate().size_hint(), (10, Some(10))); assert_eq!(vi.clone().chain(v2.iter()).size_hint(), (13, Some(13))); assert_eq!(vi.clone().zip(v2.iter()).size_hint(), (3, Some(3))); - assert_eq!(vi.clone().scan(0i, |_,_| Some(0)).size_hint(), (0, Some(10))); + assert_eq!(vi.clone().scan(0, |_,_| Some(0)).size_hint(), (0, Some(10))); assert_eq!(vi.clone().filter(|_| false).size_hint(), (0, Some(10))); assert_eq!(vi.clone().map(|&i| i+1).size_hint(), (10, Some(10))); assert_eq!(vi.filter_map(|_| Some(0)).size_hint(), (0, Some(10))); diff --git a/src/libcoretest/option.rs b/src/libcoretest/option.rs index b32ae68b5d3..860bd40e21e 100644 --- a/src/libcoretest/option.rs +++ b/src/libcoretest/option.rs @@ -223,7 +223,7 @@ fn test_ord() { /* FIXME(#20575) #[test] fn test_collect() { - let v: Option<Vec<int>> = (0..0).map(|_| Some(0i)).collect(); + let v: Option<Vec<int>> = (0..0).map(|_| Some(0)).collect(); assert!(v == Some(vec![])); let v: Option<Vec<int>> = (0..3).map(|x| Some(x)).collect(); |
