11error: impl for `HashMap` should be generalized over different hashers
2- --> $DIR/implicit_hasher.rs:15 :35
2+ --> $DIR/implicit_hasher.rs:16 :35
33 |
44LL | impl<K: Hash + Eq, V> Foo<i8> for HashMap<K, V> {
55 | ^^^^^^^^^^^^^
66 |
7- = note: `-D clippy::implicit-hasher` implied by `-D warnings`
7+ note: the lint level is defined here
8+ --> $DIR/implicit_hasher.rs:2:9
9+ |
10+ LL | #![deny(clippy::implicit_hasher)]
11+ | ^^^^^^^^^^^^^^^^^^^^^^^
812help: consider adding a type parameter
913 |
1014LL | impl<K: Hash + Eq, V, S: ::std::hash::BuildHasher + Default> Foo<i8> for HashMap<K, V, S> {
@@ -15,7 +19,7 @@ LL | (HashMap::default(), HashMap::with_capacity_and_hasher(10, Default:
1519 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1620
1721error: impl for `HashMap` should be generalized over different hashers
18- --> $DIR/implicit_hasher.rs:24 :36
22+ --> $DIR/implicit_hasher.rs:25 :36
1923 |
2024LL | impl<K: Hash + Eq, V> Foo<i8> for (HashMap<K, V>,) {
2125 | ^^^^^^^^^^^^^
@@ -30,7 +34,7 @@ LL | ((HashMap::default(),), (HashMap::with_capacity_and_hasher(10, Defa
3034 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3135
3236error: impl for `HashMap` should be generalized over different hashers
33- --> $DIR/implicit_hasher.rs:29 :19
37+ --> $DIR/implicit_hasher.rs:30 :19
3438 |
3539LL | impl Foo<i16> for HashMap<String, String> {
3640 | ^^^^^^^^^^^^^^^^^^^^^^^
@@ -45,7 +49,7 @@ LL | (HashMap::default(), HashMap::with_capacity_and_hasher(10, Default:
4549 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
4650
4751error: impl for `HashSet` should be generalized over different hashers
48- --> $DIR/implicit_hasher.rs:46 :32
52+ --> $DIR/implicit_hasher.rs:47 :32
4953 |
5054LL | impl<T: Hash + Eq> Foo<i8> for HashSet<T> {
5155 | ^^^^^^^^^^
@@ -60,7 +64,7 @@ LL | (HashSet::default(), HashSet::with_capacity_and_hasher(10, Default:
6064 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6165
6266error: impl for `HashSet` should be generalized over different hashers
63- --> $DIR/implicit_hasher.rs:51 :19
67+ --> $DIR/implicit_hasher.rs:52 :19
6468 |
6569LL | impl Foo<i16> for HashSet<String> {
6670 | ^^^^^^^^^^^^^^^
@@ -75,7 +79,7 @@ LL | (HashSet::default(), HashSet::with_capacity_and_hasher(10, Default:
7579 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
7680
7781error: parameter of type `HashMap` should be generalized over different hashers
78- --> $DIR/implicit_hasher.rs:68 :23
82+ --> $DIR/implicit_hasher.rs:69 :23
7983 |
8084LL | pub fn foo(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>) {}
8185 | ^^^^^^^^^^^^^^^^^
@@ -86,7 +90,7 @@ LL | pub fn foo<S: ::std::hash::BuildHasher>(_map: &mut HashMap<i32, i32, S>, _s
8690 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^
8791
8892error: parameter of type `HashSet` should be generalized over different hashers
89- --> $DIR/implicit_hasher.rs:68 :53
93+ --> $DIR/implicit_hasher.rs:69 :53
9094 |
9195LL | pub fn foo(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>) {}
9296 | ^^^^^^^^^^^^
@@ -97,7 +101,7 @@ LL | pub fn foo<S: ::std::hash::BuildHasher>(_map: &mut HashMap<i32, i32>, _set:
97101 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^
98102
99103error: impl for `HashMap` should be generalized over different hashers
100- --> $DIR/implicit_hasher.rs:72 :43
104+ --> $DIR/implicit_hasher.rs:73 :43
101105 |
102106LL | impl<K: Hash + Eq, V> Foo<u8> for HashMap<K, V> {
103107 | ^^^^^^^^^^^^^
@@ -116,7 +120,7 @@ LL | (HashMap::default(), HashMap::with_capacity_and_hasher(10,
116120 | ^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
117121
118122error: parameter of type `HashMap` should be generalized over different hashers
119- --> $DIR/implicit_hasher.rs:80 :33
123+ --> $DIR/implicit_hasher.rs:81 :33
120124 |
121125LL | pub fn $name(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>) {}
122126 | ^^^^^^^^^^^^^^^^^
@@ -131,7 +135,7 @@ LL | pub fn $name<S: ::std::hash::BuildHasher>(_map: &mut HashMap<i32, i
131135 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^
132136
133137error: parameter of type `HashSet` should be generalized over different hashers
134- --> $DIR/implicit_hasher.rs:80 :63
138+ --> $DIR/implicit_hasher.rs:81 :63
135139 |
136140LL | pub fn $name(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>) {}
137141 | ^^^^^^^^^^^^
0 commit comments