]> git.lizzy.rs Git - rust.git/blob - src/test/ui/span/method-and-field-eager-resolution.stderr
Add tests for #41731
[rust.git] / src / test / ui / span / method-and-field-eager-resolution.stderr
1 error[E0282]: type annotations needed
2   --> $DIR/method-and-field-eager-resolution.rs:4:9
3    |
4 LL |     let mut x = Default::default();
5    |         ^^^^^
6 LL |
7 LL |     x.0;
8    |     - type must be known at this point
9    |
10 help: consider giving `x` an explicit type
11    |
12 LL |     let mut x: _ = Default::default();
13    |              +++
14
15 error[E0282]: type annotations needed
16   --> $DIR/method-and-field-eager-resolution.rs:11:9
17    |
18 LL |     let mut x = Default::default();
19    |         ^^^^^
20 LL |
21 LL |     x[0];
22    |     - type must be known at this point
23    |
24 help: consider giving `x` an explicit type
25    |
26 LL |     let mut x: _ = Default::default();
27    |              +++
28
29 error: aborting due to 2 previous errors
30
31 For more information about this error, try `rustc --explain E0282`.