Error on resetted binding mode in edition 2024
This commit is contained in:
parent
4abbdfa1c9
commit
4107322766
12 changed files with 270 additions and 48 deletions
|
@ -1650,7 +1650,7 @@ declare_lint! {
|
|||
/// ### Example
|
||||
///
|
||||
/// ```rust,edition2021
|
||||
/// #![feature(ref_pat_eat_one_layer_2024)]
|
||||
/// #![feature(min_match_ergonomics_2024)]
|
||||
/// #![warn(rust_2024_incompatible_pat)]
|
||||
///
|
||||
/// if let Some(&a) = &Some(&0u8) {
|
||||
|
@ -1671,7 +1671,7 @@ declare_lint! {
|
|||
pub RUST_2024_INCOMPATIBLE_PAT,
|
||||
Allow,
|
||||
"detects patterns whose meaning will change in Rust 2024",
|
||||
@feature_gate = ref_pat_eat_one_layer_2024;
|
||||
@feature_gate = min_match_ergonomics_2024;
|
||||
// FIXME uncomment below upon stabilization
|
||||
/*@future_incompatible = FutureIncompatibleInfo {
|
||||
reason: FutureIncompatibilityReason::EditionSemanticsChange(Edition::Edition2024),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue