mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-12-18 09:03:18 +00:00
130 lines
2.9 KiB
Text
130 lines
2.9 KiB
Text
error: you are deriving `Hash` but have implemented `PartialEq` explicitly
|
|
--> $DIR/derive.rs:25:10
|
|
|
|
|
25 | #[derive(Hash)]
|
|
| ^^^^
|
|
|
|
|
= note: #[deny(clippy::derive_hash_xor_eq)] on by default
|
|
note: `PartialEq` implemented here
|
|
--> $DIR/derive.rs:28:1
|
|
|
|
|
28 | / impl PartialEq for Bar {
|
|
29 | | fn eq(&self, _: &Bar) -> bool {
|
|
30 | | true
|
|
31 | | }
|
|
32 | | }
|
|
| |_^
|
|
|
|
error: you are deriving `Hash` but have implemented `PartialEq` explicitly
|
|
--> $DIR/derive.rs:34:10
|
|
|
|
|
34 | #[derive(Hash)]
|
|
| ^^^^
|
|
|
|
|
note: `PartialEq` implemented here
|
|
--> $DIR/derive.rs:37:1
|
|
|
|
|
37 | / impl PartialEq<Baz> for Baz {
|
|
38 | | fn eq(&self, _: &Baz) -> bool {
|
|
39 | | true
|
|
40 | | }
|
|
41 | | }
|
|
| |_^
|
|
|
|
error: you are implementing `Hash` explicitly but have derived `PartialEq`
|
|
--> $DIR/derive.rs:46:1
|
|
|
|
|
46 | / impl Hash for Bah {
|
|
47 | | fn hash<H: Hasher>(&self, _: &mut H) {}
|
|
48 | | }
|
|
| |_^
|
|
|
|
|
note: `PartialEq` implemented here
|
|
--> $DIR/derive.rs:43:10
|
|
|
|
|
43 | #[derive(PartialEq)]
|
|
| ^^^^^^^^^
|
|
|
|
error: you are implementing `Clone` explicitly on a `Copy` type
|
|
--> $DIR/derive.rs:53:1
|
|
|
|
|
53 | / impl Clone for Qux {
|
|
54 | | fn clone(&self) -> Self {
|
|
55 | | Qux
|
|
56 | | }
|
|
57 | | }
|
|
| |_^
|
|
|
|
|
= note: `-D clippy::expl-impl-clone-on-copy` implied by `-D warnings`
|
|
note: consider deriving `Clone` or removing `Copy`
|
|
--> $DIR/derive.rs:53:1
|
|
|
|
|
53 | / impl Clone for Qux {
|
|
54 | | fn clone(&self) -> Self {
|
|
55 | | Qux
|
|
56 | | }
|
|
57 | | }
|
|
| |_^
|
|
|
|
error: you are implementing `Clone` explicitly on a `Copy` type
|
|
--> $DIR/derive.rs:77:1
|
|
|
|
|
77 | / impl<'a> Clone for Lt<'a> {
|
|
78 | | fn clone(&self) -> Self {
|
|
79 | | unimplemented!()
|
|
80 | | }
|
|
81 | | }
|
|
| |_^
|
|
|
|
|
note: consider deriving `Clone` or removing `Copy`
|
|
--> $DIR/derive.rs:77:1
|
|
|
|
|
77 | / impl<'a> Clone for Lt<'a> {
|
|
78 | | fn clone(&self) -> Self {
|
|
79 | | unimplemented!()
|
|
80 | | }
|
|
81 | | }
|
|
| |_^
|
|
|
|
error: you are implementing `Clone` explicitly on a `Copy` type
|
|
--> $DIR/derive.rs:89:1
|
|
|
|
|
89 | / impl Clone for BigArray {
|
|
90 | | fn clone(&self) -> Self {
|
|
91 | | unimplemented!()
|
|
92 | | }
|
|
93 | | }
|
|
| |_^
|
|
|
|
|
note: consider deriving `Clone` or removing `Copy`
|
|
--> $DIR/derive.rs:89:1
|
|
|
|
|
89 | / impl Clone for BigArray {
|
|
90 | | fn clone(&self) -> Self {
|
|
91 | | unimplemented!()
|
|
92 | | }
|
|
93 | | }
|
|
| |_^
|
|
|
|
error: you are implementing `Clone` explicitly on a `Copy` type
|
|
--> $DIR/derive.rs:101:1
|
|
|
|
|
101 | / impl Clone for FnPtr {
|
|
102 | | fn clone(&self) -> Self {
|
|
103 | | unimplemented!()
|
|
104 | | }
|
|
105 | | }
|
|
| |_^
|
|
|
|
|
note: consider deriving `Clone` or removing `Copy`
|
|
--> $DIR/derive.rs:101:1
|
|
|
|
|
101 | / impl Clone for FnPtr {
|
|
102 | | fn clone(&self) -> Self {
|
|
103 | | unimplemented!()
|
|
104 | | }
|
|
105 | | }
|
|
| |_^
|
|
|
|
error: aborting due to 7 previous errors
|
|
|