]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/suggest-closure-return-type-2.stderr
Rollup merge of #107559 - WaffleLapkin:is_it_2015¿, r=davidtwco
[rust.git] / tests / ui / suggestions / suggest-closure-return-type-2.stderr
1 error[E0282]: type annotations needed for `[_; 0]`
2   --> $DIR/suggest-closure-return-type-2.rs:4:18
3    |
4 LL |     unbound_drop(|| { [] })
5    |                  ^^   -- type must be known at this point
6    |
7 help: try giving this closure an explicit return type
8    |
9 LL |     unbound_drop(|| -> [_; 0] { [] })
10    |                     +++++++++
11
12 error: aborting due to previous error
13
14 For more information about this error, try `rustc --explain E0282`.