-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingE-mediumCall for participation: Medium difficulty level problem and requires some initial experience.Call for participation: Medium difficulty level problem and requires some initial experience.I-suggestion-causes-errorIssue: The suggestions provided by this Lint cause an ICE/error when appliedIssue: The suggestions provided by this Lint cause an ICE/error when appliedL-suggestionLint: Improving, adding or fixing lint suggestionsLint: Improving, adding or fixing lint suggestionsL-testsLint: Lints test codeLint: Lints test codegood first issueThese issues are a good way to get started with ClippyThese issues are a good way to get started with Clippy
Description
Perhaps related to #2042, but it seemed different enough to open a new issue.
With the following code: https://play.rust-lang.org/?gist=35d367db95cd56394d0bb9a05247b94c&version=nightly
fn main() {
let a: &str = "abc";
let b: String = "abc".to_owned();
println!("{}", a > &b);
}
Clippy complains that the reference should be removed, but removing the reference causes the code to stop compiling.
Metadata
Metadata
Assignees
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingE-mediumCall for participation: Medium difficulty level problem and requires some initial experience.Call for participation: Medium difficulty level problem and requires some initial experience.I-suggestion-causes-errorIssue: The suggestions provided by this Lint cause an ICE/error when appliedIssue: The suggestions provided by this Lint cause an ICE/error when appliedL-suggestionLint: Improving, adding or fixing lint suggestionsLint: Improving, adding or fixing lint suggestionsL-testsLint: Lints test codeLint: Lints test codegood first issueThese issues are a good way to get started with ClippyThese issues are a good way to get started with Clippy