blob: 36db5bea8629489ffd456e22c947a2ef0a4e6a44 [file] [log] [blame]
error[E0599]: no method named `f9` found for type `usize` in the current scope
--> $DIR/issue-7575.rs:62:18
|
LL | u.f8(42) + u.f9(342) + m.fff(42)
| ^^ this is an associated function, not a method
|
= note: found the following associated functions; to be used as methods, functions must have a `self` parameter
note: candidate #1 is defined in the trait `CtxtFn`
--> $DIR/issue-7575.rs:4:5
|
LL | fn f9(_: usize) -> usize;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
= help: to disambiguate the method call, write `CtxtFn::f9(u, 342)` instead
note: candidate #2 is defined in the trait `OtherTrait`
--> $DIR/issue-7575.rs:8:5
|
LL | fn f9(_: usize) -> usize;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
= help: to disambiguate the method call, write `OtherTrait::f9(u, 342)` instead
note: candidate #3 is defined in the trait `UnusedTrait`
--> $DIR/issue-7575.rs:17:5
|
LL | fn f9(_: usize) -> usize;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
= help: to disambiguate the method call, write `UnusedTrait::f9(u, 342)` instead
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following traits define an item `f9`, perhaps you need to implement one of them:
candidate #1: `CtxtFn`
candidate #2: `OtherTrait`
candidate #3: `UnusedTrait`
error[E0599]: no method named `fff` found for type `Myisize` in the current scope
--> $DIR/issue-7575.rs:62:30
|
LL | struct Myisize(isize);
| ---------------------- method `fff` not found for this
...
LL | u.f8(42) + u.f9(342) + m.fff(42)
| --^^^
| | |
| | this is an associated function, not a method
| help: use associated function syntax instead: `Myisize::fff`
|
= note: found the following associated functions; to be used as methods, functions must have a `self` parameter
note: the candidate is defined in an impl for the type `Myisize`
--> $DIR/issue-7575.rs:39:5
|
LL | fn fff(i: isize) -> isize {
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0599]: no method named `is_str` found for type `T` in the current scope
--> $DIR/issue-7575.rs:70:7
|
LL | t.is_str()
| ^^^^^^ this is an associated function, not a method
|
= note: found the following associated functions; to be used as methods, functions must have a `self` parameter
note: the candidate is defined in the trait `ManyImplTrait`
--> $DIR/issue-7575.rs:45:5
|
LL | fn is_str() -> bool {
| ^^^^^^^^^^^^^^^^^^^
= help: to disambiguate the method call, write `ManyImplTrait::is_str(t)` instead
= help: items from traits can only be used if the type parameter is bounded by the trait
help: the following trait defines an item `is_str`, perhaps you need to restrict type parameter `T` with it:
|
LL | fn param_bound<T: ManyImplTrait + ManyImplTrait>(t: T) -> bool {
| ^^^^^^^^^^^^^^^^^^
error: aborting due to 3 previous errors
For more information about this error, try `rustc --explain E0599`.