mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-17 05:25:37 +03:00
clean up E0404 explanation
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
You tried to use something which is not a trait in a trait position, such as
|
||||
a bound or `impl`.
|
||||
A type that is not a trait was used in a trait position, such as a bound
|
||||
or `impl`.
|
||||
|
||||
Erroneous code example:
|
||||
|
||||
@@ -18,8 +18,8 @@ struct Foo;
|
||||
fn bar<T: Foo>(t: T) {} // error: `Foo` is not a trait
|
||||
```
|
||||
|
||||
Please verify that you didn't misspell the trait's name or otherwise use the
|
||||
wrong identifier. Example:
|
||||
Please verify that the trait's name was not misspelled or that the right
|
||||
identifier was used. Example:
|
||||
|
||||
```
|
||||
trait Foo {
|
||||
@@ -32,7 +32,7 @@ impl Foo for Bar { // ok!
|
||||
}
|
||||
```
|
||||
|
||||
or
|
||||
or:
|
||||
|
||||
```
|
||||
trait Foo {
|
||||
|
||||
Reference in New Issue
Block a user