rust/tests/ui/error-codes/E0221.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

40 lines
1.2 KiB
Plaintext
Raw Normal View History

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