1 error[E0282]: type annotations needed for `Vec<T>`
2 --> $DIR/method-ambig-one-trait-unknown-int-type.rs:24:9
4 LL | let mut x = Vec::new();
7 help: consider giving `x` an explicit type, where the type for type parameter `T` is specified
9 LL | let mut x: Vec<T> = Vec::new();
12 error[E0283]: type annotations needed
13 --> $DIR/method-ambig-one-trait-unknown-int-type.rs:26:7
16 | ^^^ cannot infer type for struct `Vec<_>`
18 note: multiple `impl`s satisfying `Vec<_>: Foo` found
19 --> $DIR/method-ambig-one-trait-unknown-int-type.rs:9:1
21 LL | impl Foo for Vec<usize> {
22 | ^^^^^^^^^^^^^^^^^^^^^^^
24 LL | impl Foo for Vec<isize> {
25 | ^^^^^^^^^^^^^^^^^^^^^^^
27 error[E0308]: mismatched types
28 --> $DIR/method-ambig-one-trait-unknown-int-type.rs:33:20
30 LL | let y: usize = x.foo();
31 | ----- ^^^^^^^ expected `usize`, found `isize`
33 | expected due to this
35 help: you can convert an `isize` to a `usize` and panic if the converted value doesn't fit
37 LL | let y: usize = x.foo().try_into().unwrap();
38 | ++++++++++++++++++++
40 error: aborting due to 3 previous errors
42 Some errors have detailed explanations: E0282, E0283, E0308.
43 For more information about an error, try `rustc --explain E0282`.