Skip to content

Commit 3f07043

Browse files
committed
while desugars to loop so 'a: while break 'a {} in ctfe doesn't work yet.
1 parent 09c2193 commit 3f07043

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

src/test/run-pass/consts/const-labeled-break.rs renamed to src/test/ui/consts/const-labeled-break.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
// See https://github.com/rust-lang/rust/issues/51350 for more information.
55

66
const CRASH: () = 'a: while break 'a {};
7+
//~^ ERROR constant contains unimplemented expression type
78

8-
fn main() {
9-
println!("{:?}", CRASH);
10-
}
9+
fn main() {}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
error[E0019]: constant contains unimplemented expression type
2+
--> $DIR/const-labeled-break.rs:6:19
3+
|
4+
LL | const CRASH: () = 'a: while break 'a {};
5+
| ^^^^^^^^^^^^^^^^^^^^^
6+
7+
error: aborting due to previous error
8+
9+
For more information about this error, try `rustc --explain E0019`.

0 commit comments

Comments
 (0)