mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-12-19 17:44:21 +00:00
224916823a
- Create hir_crate_items query which traverses tcx.hir_crate(()).owners to return a hir::ModuleItems - use tcx.hir_crate_items in tcx.hir().items() to return an iterator of hir::ItemId - add par_items(impl Fn(hir::ItemId)) to traverse all items in parallel Signed-off-by: Miguel Guarniz <mi9uel9@gmail.com>
64 lines
1.7 KiB
Text
64 lines
1.7 KiB
Text
error: method's name is the same as an existing method in a trait
|
|
--> $DIR/same_name_method.rs:20:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
|
= note: `-D clippy::same-name-method` implied by `-D warnings`
|
|
note: existing `foo` defined here
|
|
--> $DIR/same_name_method.rs:24:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
error: method's name is the same as an existing method in a trait
|
|
--> $DIR/same_name_method.rs:34:13
|
|
|
|
|
LL | fn clone() {}
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
note: existing `clone` defined here
|
|
--> $DIR/same_name_method.rs:30:18
|
|
|
|
|
LL | #[derive(Clone)]
|
|
| ^^^^^
|
|
= note: this error originates in the derive macro `Clone` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error: method's name is the same as an existing method in a trait
|
|
--> $DIR/same_name_method.rs:44:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
|
note: existing `foo` defined here
|
|
--> $DIR/same_name_method.rs:48:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
error: method's name is the same as an existing method in a trait
|
|
--> $DIR/same_name_method.rs:58:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
|
note: existing `foo` defined here
|
|
--> $DIR/same_name_method.rs:61:9
|
|
|
|
|
LL | impl T1 for S {}
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
error: method's name is the same as an existing method in a trait
|
|
--> $DIR/same_name_method.rs:70:13
|
|
|
|
|
LL | fn foo() {}
|
|
| ^^^^^^^^^^^
|
|
|
|
|
note: existing `foo` defined here
|
|
--> $DIR/same_name_method.rs:73:9
|
|
|
|
|
LL | impl T1 for S {}
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
error: aborting due to 5 previous errors
|
|
|