summaryrefslogtreecommitdiffstats
path: root/tests/ui/inference/question-mark-type-infer.stderr
blob: 7a1e850d157fe7f4f5b2505794fc3d38c96cdeb1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
error[E0282]: type annotations needed
  --> $DIR/question-mark-type-infer.rs:10:21
   |
LL |     l.iter().map(f).collect()?
   |                     ^^^^^^^ cannot infer type of the type parameter `B` declared on the method `collect`
   |
help: consider specifying the generic argument
   |
LL |     l.iter().map(f).collect::<Vec<_>>()?
   |                            ++++++++++

error: aborting due to previous error

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