Skip to content

Commit f78b9ad

Browse files
committed
Alpha-rename label to avoid the shadowing lint (which cannot be silenced).
1 parent 175d7f4 commit f78b9ad

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/test/ui/run-pass/for-loop-while/loop-labeled-break-value.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ fn main() {
1515
'outer: loop {
1616
let _: i32 = loop { break 'outer };
1717
}
18-
'outer: loop {
19-
let _: i32 = loop { loop { break 'outer } };
18+
'outer2: loop {
19+
let _: i32 = loop { loop { break 'outer2 } };
2020
}
2121
}

src/test/ui/run-pass/for-loop-while/while-let.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ pub fn main() {
3636

3737
pq = make_pq();
3838
sum = 0;
39-
'a: while let Some(x) = pq.pop() {
39+
'a2: while let Some(x) = pq.pop() {
4040
if x == 3 {
41-
continue 'a;
41+
continue 'a2;
4242
}
4343
sum += x;
4444
}

0 commit comments

Comments
 (0)