error[E0277]: the trait bound `dyn Trait: Trait` is not satisfied
--> $DIR/more-object-bound.rs:12:17
|
LL | foo::>(x)
| ^^^^^^^^^^^^^^^^^^^^^^^ the trait `Trait` is not implemented for `dyn Trait`
|
note: required by a bound in `foo`
--> $DIR/more-object-bound.rs:18:8
|
LL | fn foo(x: T::A) -> B
| --- required by a bound in this function
LL | where
LL | T: Trait,
| ^^^^^^^^^^^^ required by this bound in `foo`
help: consider introducing a `where` clause, but there might be an alternative better way to express this requirement
|
LL | fn transmute(x: A) -> B where dyn Trait: Trait {
| ++++++++++++++++++++++++++++++++++++
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.