uncomment code that was commented out for testing
This commit is contained in:
parent
1ba8ed96cf
commit
2e63a5648a
@ -122,22 +122,22 @@ fn if_same_then_else() -> Result<&'static str, ()> {
|
||||
if true {
|
||||
//~^NOTE same as this
|
||||
for _ in &[42] {
|
||||
// let foo: &Option<_> = &Some::<u8>(42);
|
||||
// if true {
|
||||
// break;
|
||||
// } else {
|
||||
// continue;
|
||||
// }
|
||||
let foo: &Option<_> = &Some::<u8>(42);
|
||||
if true {
|
||||
break;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
else { //~ERROR this `if` has identical blocks
|
||||
for _ in &[42] {
|
||||
// let foo: &Option<_> = &Some::<u8>(42);
|
||||
// if true {
|
||||
// break;
|
||||
// } else {
|
||||
// continue;
|
||||
// }
|
||||
let foo: &Option<_> = &Some::<u8>(42);
|
||||
if true {
|
||||
break;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user