Add a test for #2171

This commit is contained in:
topecongiro 2017-11-20 16:38:15 +09:00
parent f987946078
commit 44d81d9e0e
2 changed files with 20 additions and 0 deletions

View file

@ -188,3 +188,13 @@ fn issue1524() {
let f = |x| {x};
let f = |x| x;
}
fn issue2171() {
foo(|| unsafe {
if PERIPHERALS {
loop {}
} else {
PERIPHERALS = true;
}
})
}

View file

@ -220,3 +220,13 @@ fn issue1524() {
let f = |x| x;
let f = |x| x;
}
fn issue2171() {
foo(|| unsafe {
if PERIPHERALS {
loop {}
} else {
PERIPHERALS = true;
}
})
}