Skip to content

Commit f8e50d8

Browse files
max-niedermanNadrieril
authored andcommitted
add guard_patterns unstable feature, without unstable book chapter for now
1 parent ab3cf26 commit f8e50d8

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

compiler/rustc_feature/src/unstable.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -504,6 +504,8 @@ declare_features! (
504504
(incomplete, generic_const_items, "1.73.0", Some(113521)),
505505
/// Allows registering static items globally, possibly across crates, to iterate over at runtime.
506506
(unstable, global_registration, "1.80.0", Some(125119)),
507+
/// Allows using guards in patterns.
508+
(incomplete, guard_patterns, "CURRENT_RUSTC_VERSION", Some(129967)),
507509
/// Allows using `..=X` as a patterns in slices.
508510
(unstable, half_open_range_patterns_in_slices, "1.66.0", Some(67264)),
509511
/// Allows `if let` guard in match arms.

compiler/rustc_span/src/symbol.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -985,6 +985,7 @@ symbols! {
985985
global_registration,
986986
globs,
987987
gt,
988+
guard_patterns,
988989
half_open_range_patterns,
989990
half_open_range_patterns_in_slices,
990991
hash,

0 commit comments

Comments
 (0)