mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-02 10:18:25 +00:00
35 lines
1.2 KiB
Plaintext
35 lines
1.2 KiB
Plaintext
error[E0207]: the type parameter `T` is not constrained by the impl trait, self type, or predicates
|
|
--> $DIR/unconstrained-projection-normalization.rs:13:6
|
|
|
|
|
LL | impl<T: ?Sized> Every for Thing {
|
|
| ^ unconstrained type parameter
|
|
|
|
error[E0277]: the size for values of type `T` cannot be known at compilation time
|
|
--> $DIR/unconstrained-projection-normalization.rs:15:18
|
|
|
|
|
LL | impl<T: ?Sized> Every for Thing {
|
|
| - this type parameter needs to be `Sized`
|
|
LL |
|
|
LL | type Assoc = T;
|
|
| ^ doesn't have a size known at compile-time
|
|
|
|
|
note: required by a bound in `Every::Assoc`
|
|
--> $DIR/unconstrained-projection-normalization.rs:11:5
|
|
|
|
|
LL | type Assoc;
|
|
| ^^^^^^^^^^^ required by this bound in `Every::Assoc`
|
|
help: consider removing the `?Sized` bound to make the type parameter `Sized`
|
|
|
|
|
LL - impl<T: ?Sized> Every for Thing {
|
|
LL + impl<T> Every for Thing {
|
|
|
|
|
help: consider relaxing the implicit `Sized` restriction
|
|
|
|
|
LL | type Assoc: ?Sized;
|
|
| ++++++++
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
Some errors have detailed explanations: E0207, E0277.
|
|
For more information about an error, try `rustc --explain E0207`.
|