Skip to content

Commit

Permalink
Example changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexendoo committed Jun 14, 2024
1 parent 346ce89 commit 602d81e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
2 changes: 1 addition & 1 deletion clippy_lints/src/manual_is_ascii_check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ fn check_is_ascii(
cx,
MANUAL_IS_ASCII_CHECK,
span,
"manual check for common ascii range",
"manual check for common ASCII range",
|diag| {
diag.multipart_suggestion("try", suggestion, app);
},
Expand Down
20 changes: 11 additions & 9 deletions clippy_lints/src/operators/identity_op.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,13 +239,15 @@ fn span_ineffective_operation(
Parens::Unneeded => expr_snippet,
};

span_lint_and_sugg(
cx,
IDENTITY_OP,
span,
"this operation has no effect",
"consider reducing it to",
suggestion,
applicability,
);
if false {
span_lint_and_sugg(
cx,
IDENTITY_OP,
span,
"this operation has no effect",
"consider reducing it to",
suggestion,
applicability,
);
}
}

0 comments on commit 602d81e

Please sign in to comment.