]> git.lizzy.rs Git - rust.git/blob - tests/pretty/disamb-stmt-expr.rs
Remove both StorageLive and StorageDead in CopyProp.
[rust.git] / tests / pretty / disamb-stmt-expr.rs
1 // pp-exact
2
3 // Here we check that the parentheses around the body of `wsucc()` are
4 // preserved.  They are needed to disambiguate `{return n+1}; - 0` from
5 // `({return n+1}-0)`.
6
7 fn id<F>(f: F) -> isize where F: Fn() -> isize { f() }
8
9 fn wsucc(_n: isize) -> isize { id(|| { 1 }) - 0 }
10 fn main() {}