about summary refs log tree commit diff
path: root/src/libstd/vec.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/vec.rs')
-rw-r--r--src/libstd/vec.rs11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/libstd/vec.rs b/src/libstd/vec.rs
index 0adc6083f6b..b4764f577cb 100644
--- a/src/libstd/vec.rs
+++ b/src/libstd/vec.rs
@@ -3395,7 +3395,6 @@ mod tests {
 
     #[test]
     fn test_permutations() {
-        use hashmap;
         {
             let v: [int, ..0] = [];
             let mut it = v.permutations();
@@ -3418,13 +3417,13 @@ mod tests {
             assert_eq!(it.next(), None);
         }
         {
-            // check that we have N! unique permutations
-            let mut set = hashmap::HashSet::new();
+            // check that we have N! permutations
             let v = ['A', 'B', 'C', 'D', 'E', 'F'];
-            for perm in v.permutations() {
-                set.insert(perm);
+            let mut amt = 0;
+            for _perm in v.permutations() {
+                amt += 1;
             }
-            assert_eq!(set.len(), 2 * 3 * 4 * 5 * 6);
+            assert_eq!(amt, 2 * 3 * 4 * 5 * 6);
         }
     }