]> git.proxmox.com Git - rustc.git/blob - src/test/ui/parser/regions-out-of-scope-slice.rs
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / parser / regions-out-of-scope-slice.rs
1 // This basically tests the parser's recovery on `'blk` in the wrong place.
2
3 fn foo(cond: bool) {
4 let mut x;
5
6 if cond {
7 x = &'blk [1,2,3]; //~ ERROR borrow expressions cannot be annotated with lifetimes
8 }
9 }
10
11 fn main() {}