rust/src/test/ui/traits/trait-bounds-on-structs-and-enums-static.stderr

19 lines
527 B
Plaintext

error[E0277]: the trait bound `usize: Trait` is not satisfied
--> $DIR/trait-bounds-on-structs-and-enums-static.rs:19:1
|
LL | / static X: Foo<usize> = Foo {
LL | | //~^ ERROR E0277
LL | | x: 1,
LL | | };
| |__^ the trait `Trait` is not implemented for `usize`
|
note: required by `Foo`
--> $DIR/trait-bounds-on-structs-and-enums-static.rs:15:1
|
LL | struct Foo<T:Trait> {
| ^^^^^^^^^^^^^^^^^^^
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.