Rollup merge of #32766 - nikomatsakis:constant-pattern-warning-cycle, r=eddyb
change constant patterns to have a warning cycle This was the original intention :( r? @eddyb
This commit is contained in:
@@ -144,7 +144,7 @@ declare_lint! {
|
|||||||
|
|
||||||
declare_lint! {
|
declare_lint! {
|
||||||
pub ILLEGAL_STRUCT_OR_ENUM_CONSTANT_PATTERN,
|
pub ILLEGAL_STRUCT_OR_ENUM_CONSTANT_PATTERN,
|
||||||
Deny,
|
Warn,
|
||||||
"constants of struct or enum type can only be used in a pattern if \
|
"constants of struct or enum type can only be used in a pattern if \
|
||||||
the struct or enum has `#[derive(PartialEq, Eq)]`"
|
the struct or enum has `#[derive(PartialEq, Eq)]`"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user