-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
apply review suggestions by @Centri3: use multi suggestion; change output message format; add macro expansion check & tests;
- Loading branch information
Showing
4 changed files
with
140 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,60 +1,52 @@ | ||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:21:13 | ||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:22:13 | ||
| | ||
LL | fn from(b: B) -> Self { | ||
| ^ | ||
| ^ help: consider using the default name: `value` | ||
| | ||
= help: consider changing the name to: 'value' | ||
= note: `-D clippy::renamed-function-params` implied by `-D warnings` | ||
= help: to override `-D warnings` add `#[allow(clippy::renamed_function_params)]` | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:27:18 | ||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:28:18 | ||
| | ||
LL | fn eq(&self, rhs: &Self) -> bool { | ||
| ^^^ | ||
| | ||
= help: consider changing the name to: 'other' | ||
| ^^^ help: consider using the default name: `other` | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:31:18 | ||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:32:18 | ||
| | ||
LL | fn ne(&self, rhs: &Self) -> bool { | ||
| ^^^ | ||
| | ||
= help: consider changing the name to: 'other' | ||
| ^^^ help: consider using the default name: `other` | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:44:19 | ||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:45:19 | ||
| | ||
LL | fn foo(&self, i_dont_wanna_use_your_name: u8) {} | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
| | ||
= help: consider changing the name to: 'val' | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using the default name: `val` | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:51:31 | ||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:52:31 | ||
| | ||
LL | fn hash<H: Hasher>(&self, states: &mut H) { | ||
| ^^^^^^ | ||
| | ||
= help: consider changing the name to: 'state' | ||
| ^^^^^^ help: consider using the default name: `state` | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:55:30 | ||
error: renamed function parameters of trait impl | ||
--> $DIR/renamed_function_params.rs:56:30 | ||
| | ||
LL | fn hash_slice<H: Hasher>(date: &[Self], states: &mut H) { | ||
| ^^^^ | ||
| ^^^^ ^^^^^^ | ||
| | ||
= help: consider changing the name to: 'data' | ||
|
||
error: function parameter name was renamed from its trait default | ||
--> $DIR/renamed_function_params.rs:55:45 | ||
help: consider using the default names | ||
| | ||
LL | fn hash_slice<H: Hasher>(date: &[Self], states: &mut H) { | ||
| ^^^^^^ | ||
LL | fn hash_slice<H: Hasher>(data: &[Self], state: &mut H) { | ||
| ~~~~ ~~~~~ | ||
|
||
error: renamed function parameter of trait impl | ||
--> $DIR/renamed_function_params.rs:77:18 | ||
| | ||
= help: consider changing the name to: 'state' | ||
LL | fn add(self, b: B) -> C { | ||
| ^ help: consider using the default name: `rhs` | ||
|
||
error: aborting due to 7 previous errors | ||
|