]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/return/return-match-array-const.rs
2 [(); return match 0 { n => n }
];
3 //~^ ERROR: return statement outside of function body
4 //~| ERROR: `match` is not allowed in a `const`
6 [(); return match 0 { 0 => 0 }
];
7 //~^ ERROR: return statement outside of function body
8 //~| ERROR: `match` is not allowed in a `const`
10 [(); return match () { 'a' => 0, _ => 0 }
];
11 //~^ ERROR: return statement outside of function body
12 //~| ERROR: `match` is not allowed in a `const`