]> git.lizzy.rs Git - rust.git/blob - tests/ui/async-await/issues/issue-95307.rs
Rollup merge of #106944 - Nilstrieb:there-once-was-a-diagnostic, r=WaffleLapkin
[rust.git] / tests / ui / async-await / issues / issue-95307.rs
1 // edition:2018
2
3 // Regression test for #95307.
4 // The ICE occurred on all the editions, specifying edition:2018 to reduce diagnostics.
5
6 pub trait C {
7     async fn new() -> [u8; _];
8     //~^ ERROR: functions in traits cannot be declared `async`
9     //~| ERROR: using `_` for array lengths is unstable
10     //~| ERROR: in expressions, `_` can only be used on the left-hand side of an assignment
11 }
12
13 fn main() {}