1 #![warn(unused_labels)]
4 'while_loop: while true { //~ WARN denote infinite loops with
7 //~^ ERROR cannot find value `while_loop` in this scope
9 'while_let: while let Some(_) = Some(()) {
10 //~^ WARN unused label
12 //~^ ERROR cannot find value `while_let` in this scope
14 'for_loop: for _ in 0..3 {
15 //~^ WARN unused label
17 //~^ ERROR cannot find value `for_loop` in this scope
20 //~^ WARN unused label
22 //~^ ERROR cannot find value `LOOP` in this scope
29 //~^ ERROR cannot find value `LOOP` in this scope
31 'while_loop: while true { //~ WARN denote infinite loops with
33 //~^ ERROR cannot find value `while_loop` in this scope
35 'while_let: while let Some(_) = Some(()) {
37 //~^ ERROR cannot find value `while_let` in this scope
39 'for_loop: for _ in 0..3 {
41 //~^ ERROR cannot find value `for_loop` in this scope
47 'while_loop: while true { //~ WARN denote infinite loops with
48 //~^ WARN unused label
50 //~^ ERROR `break` with value from a `while` loop
52 'while_let: while let Some(_) = Some(()) {
53 //~^ WARN unused label
55 //~^ ERROR `break` with value from a `while` loop
57 'for_loop: for _ in 0..3 {
58 //~^ WARN unused label
60 //~^ ERROR `break` with value from a `for` loop