2018-02-08 11:35:35 +08:00
|
|
|
error[E0221]: ambiguous associated type `A` in bounds of `Self`
|
2018-12-25 23:56:47 +08:00
|
|
|
--> $DIR/E0221.rs:11:16
|
2018-02-08 11:35:35 +08:00
|
|
|
|
|
2018-02-23 08:42:32 +08:00
|
|
|
LL | type A: T1;
|
2022-02-13 23:27:59 +08:00
|
|
|
| ---------- ambiguous `A` from `Foo`
|
2018-02-08 11:35:35 +08:00
|
|
|
...
|
2018-02-23 08:42:32 +08:00
|
|
|
LL | type A: T2;
|
2022-02-13 23:27:59 +08:00
|
|
|
| ---------- ambiguous `A` from `Bar`
|
2018-02-25 07:01:39 +08:00
|
|
|
LL | fn do_something() {
|
2018-02-23 08:42:32 +08:00
|
|
|
LL | let _: Self::A;
|
2018-02-08 11:35:35 +08:00
|
|
|
| ^^^^^^^ ambiguous associated type `A`
|
2019-12-13 06:48:46 +08:00
|
|
|
|
|
2023-10-17 02:25:11 +08:00
|
|
|
help: use fully-qualified syntax to disambiguate
|
2019-12-13 06:48:46 +08:00
|
|
|
|
|
|
|
|
LL | let _: <Self as Foo>::A;
|
2021-08-10 18:53:43 +08:00
|
|
|
| ~~~~~~~~~~~~~~~
|
2023-10-17 02:25:11 +08:00
|
|
|
help: use fully-qualified syntax to disambiguate
|
2019-12-13 06:48:46 +08:00
|
|
|
|
|
|
|
|
LL | let _: <Self as Bar>::A;
|
2021-08-10 18:53:43 +08:00
|
|
|
| ~~~~~~~~~~~~~~~
|
2018-02-08 11:35:35 +08:00
|
|
|
|
|
|
|
error[E0221]: ambiguous associated type `Err` in bounds of `Self`
|
2018-12-25 23:56:47 +08:00
|
|
|
--> $DIR/E0221.rs:21:16
|
2018-02-08 11:35:35 +08:00
|
|
|
|
|
2018-02-23 08:42:32 +08:00
|
|
|
LL | type Err: T3;
|
2022-02-13 23:27:59 +08:00
|
|
|
| ------------ ambiguous `Err` from `My`
|
2018-02-25 07:01:39 +08:00
|
|
|
LL | fn test() {
|
2018-02-23 08:42:32 +08:00
|
|
|
LL | let _: Self::Err;
|
2021-08-10 18:53:43 +08:00
|
|
|
| ^^^^^^^^^ ambiguous associated type `Err`
|
2019-12-13 06:48:46 +08:00
|
|
|
|
|
2023-11-24 16:53:10 +08:00
|
|
|
= note: associated type `Err` could derive from `FromStr`
|
2023-10-17 02:25:11 +08:00
|
|
|
help: use fully-qualified syntax to disambiguate
|
2021-08-10 18:53:43 +08:00
|
|
|
|
|
|
|
|
LL | let _: <Self as My>::Err;
|
|
|
|
| ~~~~~~~~~~~~~~
|
2018-02-08 11:35:35 +08:00
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
2018-03-03 22:59:40 +08:00
|
|
|
For more information about this error, try `rustc --explain E0221`.
|