-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingI-false-negativeIssue: The lint should have been triggered on code, but wasn'tIssue: The lint should have been triggered on code, but wasn't
Description
Summary
derivable_impls
FN when enum is qualified with Self
in its impl of Default
Lint Name
derivable_impls
Reproducer
I tried this code:
#[derive(Copy, Clone)]
enum Bar {
A,
B,
}
impl Default for Bar {
fn default() -> Self {
Self::A
}
}
I expected to see this happen:
The lint is triggered for Bar
Instead, this happened:
Nothing
Version
Metadata
Metadata
Assignees
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingI-false-negativeIssue: The lint should have been triggered on code, but wasn'tIssue: The lint should have been triggered on code, but wasn't