]> git.proxmox.com Git - rustc.git/blame - src/test/ui/methods/method-ambig-two-traits-from-bounds.stderr
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / methods / method-ambig-two-traits-from-bounds.stderr
CommitLineData
b7449926 1error[E0034]: multiple applicable items in scope
0731742a 2 --> $DIR/method-ambig-two-traits-from-bounds.rs:5:7
b7449926 3 |
532ac7d7 4LL | t.foo();
b7449926
XL
5 | ^^^ multiple `foo` found
6 |
7note: candidate #1 is defined in the trait `A`
0731742a 8 --> $DIR/method-ambig-two-traits-from-bounds.rs:1:11
b7449926
XL
9 |
10LL | trait A { fn foo(&self); }
11 | ^^^^^^^^^^^^^^
b7449926 12note: candidate #2 is defined in the trait `B`
0731742a 13 --> $DIR/method-ambig-two-traits-from-bounds.rs:2:11
b7449926
XL
14 |
15LL | trait B { fn foo(&self); }
16 | ^^^^^^^^^^^^^^
ba9703b0 17help: disambiguate the associated function for candidate #1
dfeec247
XL
18 |
19LL | A::foo(t);
20 | ^^^^^^^^^
ba9703b0 21help: disambiguate the associated function for candidate #2
dfeec247
XL
22 |
23LL | B::foo(t);
24 | ^^^^^^^^^
b7449926
XL
25
26error: aborting due to previous error
27
28For more information about this error, try `rustc --explain E0034`.