blob: 42b76a8f7ff6771a2fd38d84243d615d7028f791 [file] [log] [blame]
error[E0283]: type annotations needed
--> $DIR/forced_ambiguity-use-head-maybe-cause.rs:43:19
|
LL | impls_trait::<Root<_>>()
| ^^^^^^^ cannot infer type for struct `Head<_>`
|
= note: cannot satisfy `Head<_>: Trait`
help: the following types implement trait `Trait`
--> $DIR/forced_ambiguity-use-head-maybe-cause.rs:23:1
|
LL | / impl<T> Trait for Head<T>
LL | | where
LL | | Root<T>: Trait,
LL | | T: Trait, // ambiguous
| |_____________^ `Head<T>`
...
LL | / impl<T> Trait for Head<T>
LL | | where
LL | | Error<T>: Trait,
LL | | NotImplemented<T>: Trait,
| |_____________________________^ `Head<T>`
note: required for `Root<_>` to implement `Trait`
--> $DIR/forced_ambiguity-use-head-maybe-cause.rs:18:9
|
LL | impl<T> Trait for Root<T>
| ^^^^^ ^^^^^^^
LL | where
LL | Head<T>: Trait,
| ----- unsatisfied trait bound introduced here
= note: 8 redundant requirements hidden
= note: required for `Root<_>` to implement `Trait`
note: required by a bound in `impls_trait`
--> $DIR/forced_ambiguity-use-head-maybe-cause.rs:41:19
|
LL | fn impls_trait<T: Trait>() {}
| ^^^^^ required by this bound in `impls_trait`
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0283`.