Skip to content

Commit 4feec41

Browse files
committed
#![feature(inline_const_pat)] is no longer incomplete
1 parent 11f32b7 commit 4feec41

25 files changed

+28
-53
lines changed

compiler/rustc_feature/src/unstable.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,7 @@ declare_features! (
496496
/// Allow anonymous constants from an inline `const` block
497497
(unstable, inline_const, "1.49.0", Some(76001)),
498498
/// Allow anonymous constants from an inline `const` block in pattern position
499-
(incomplete, inline_const_pat, "1.58.0", Some(76001)),
499+
(unstable, inline_const_pat, "1.58.0", Some(76001)),
500500
/// Allows using `pointer` and `reference` in intra-doc links
501501
(unstable, intra_doc_pointers, "1.51.0", Some(80896)),
502502
// Allows setting the threshold for the `large_assignments` lint.

tests/ui/consts/invalid-inline-const-in-match-arm.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#![allow(incomplete_features)]
21
#![feature(inline_const_pat)]
32

43
fn main() {

tests/ui/consts/invalid-inline-const-in-match-arm.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0015]: cannot call non-const closure in constants
2-
--> $DIR/invalid-inline-const-in-match-arm.rs:6:17
2+
--> $DIR/invalid-inline-const-in-match-arm.rs:5:17
33
|
44
LL | const { (|| {})() } => {}
55
| ^^^^^^^^^

tests/ui/half-open-range-patterns/range_pat_interactions0.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// run-pass
2-
#![allow(incomplete_features)]
32
#![feature(exclusive_range_pattern)]
43
#![feature(inline_const_pat)]
54

tests/ui/inline-const/const-match-pat-generic.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#![allow(incomplete_features)]
21
#![feature(inline_const_pat)]
32

43
// rust-lang/rust#82518: ICE with inline-const in match referencing const-generic parameter

tests/ui/inline-const/const-match-pat-generic.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
error: constant pattern depends on a generic parameter
2-
--> $DIR/const-match-pat-generic.rs:8:9
2+
--> $DIR/const-match-pat-generic.rs:7:9
33
|
44
LL | const { V } => {},
55
| ^^^^^^^^^^^
66

77
error: constant pattern depends on a generic parameter
8-
--> $DIR/const-match-pat-generic.rs:20:9
8+
--> $DIR/const-match-pat-generic.rs:19:9
99
|
1010
LL | const { f(V) } => {},
1111
| ^^^^^^^^^^^^^^

tests/ui/inline-const/const-match-pat-inference.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
// check-pass
22

33
#![feature(inline_const_pat)]
4-
#![allow(incomplete_features)]
54

65
fn main() {
76
match 1u64 {

tests/ui/inline-const/const-match-pat-lifetime-err.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#![allow(incomplete_features)]
21
#![feature(const_mut_refs)]
32
#![feature(inline_const_pat)]
43

tests/ui/inline-const/const-match-pat-lifetime-err.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0597]: `y` does not live long enough
2-
--> $DIR/const-match-pat-lifetime-err.rs:29:29
2+
--> $DIR/const-match-pat-lifetime-err.rs:28:29
33
|
44
LL | fn match_invariant_ref<'a>() {
55
| -- lifetime `'a` defined here
@@ -15,7 +15,7 @@ LL | }
1515
| - `y` dropped here while still borrowed
1616

1717
error: lifetime may not live long enough
18-
--> $DIR/const-match-pat-lifetime-err.rs:39:12
18+
--> $DIR/const-match-pat-lifetime-err.rs:38:12
1919
|
2020
LL | fn match_covariant_ref<'a>() {
2121
| -- lifetime `'a` defined here

tests/ui/inline-const/const-match-pat-lifetime.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
// run-pass
22

3-
#![allow(incomplete_features)]
43
#![feature(const_mut_refs)]
54
#![feature(inline_const)]
65
#![feature(inline_const_pat)]

0 commit comments

Comments
 (0)