summaryrefslogtreecommitdiffstats
path: root/src/test/ui/suggestions/suggest-closure-return-type-1.stderr
blob: f4c2eb7ff34ae1e76d66f454df31a557abc0f1c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
error[E0282]: type annotations needed for `[_; 0]`
  --> $DIR/suggest-closure-return-type-1.rs:4:18
   |
LL |     unbound_drop(|| -> _ { [] });
   |                  ^^^^^^^   -- type must be known at this point
   |
help: try giving this closure an explicit return type
   |
LL |     unbound_drop(|| -> [_; 0] { [] });
   |                        ~~~~~~

error: aborting due to previous error

For more information about this error, try `rustc --explain E0282`.