Deleted unused labels from compiler and fixed or allowed unused labels in tests. This patch removes some gratuitous unused labels and turns off the warning for unused labels that are a necessary part of tests. This will permit setting the `unused_labels` lint to `warn`.
12 lines
195 B
Rust
12 lines
195 B
Rust
// run-pass
|
|
// Issue #12512.
|
|
|
|
// pretty-expanded FIXME #23616
|
|
|
|
fn main() {
|
|
let mut foo = Vec::new();
|
|
#[allow(unused_labels)]
|
|
'foo: for i in &[1, 2, 3] {
|
|
foo.push(*i);
|
|
}
|
|
}
|