mirror of
https://github.com/rust-lang/rust.git
synced 2025-09-30 00:03:49 +00:00

When encountering an unmet trait bound, point at local type that doesn't implement the trait: ``` error[E0277]: the trait bound `Bar<T>: Foo` is not satisfied --> $DIR/issue-64855.rs:9:19 | LL | pub struct Bar<T>(<Self as Foo>::Type) where Self: ; | ^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound | help: the trait `Foo` is not implemented for `Bar<T>` --> $DIR/issue-64855.rs:9:1 | LL | pub struct Bar<T>(<Self as Foo>::Type) where Self: ; | ^^^^^^^^^^^^^^^^^ ```
47 lines
2.0 KiB
Plaintext
47 lines
2.0 KiB
Plaintext
error[E0277]: `Helper<'a, T>` is not an iterator
|
|
--> $DIR/inherent-bound-in-probe.rs:39:21
|
|
|
|
|
LL | type IntoIter = Helper<'a, T>;
|
|
| ^^^^^^^^^^^^^ `Helper<'a, T>` is not an iterator
|
|
|
|
|
help: the trait `Iterator` is not implemented for `Helper<'a, T>`
|
|
--> $DIR/inherent-bound-in-probe.rs:15:1
|
|
|
|
|
LL | struct Helper<'a, T>
|
|
| ^^^^^^^^^^^^^^^^^^^^
|
|
note: required by a bound in `std::iter::IntoIterator::IntoIter`
|
|
--> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
|
|
|
|
error[E0275]: overflow evaluating the requirement `&_: IntoIterator`
|
|
--> $DIR/inherent-bound-in-probe.rs:43:9
|
|
|
|
|
LL | Helper::new(&self.0)
|
|
| ^^^^^^
|
|
|
|
|
= help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`inherent_bound_in_probe`)
|
|
note: required for `&BitReaderWrapper<_>` to implement `IntoIterator`
|
|
--> $DIR/inherent-bound-in-probe.rs:33:13
|
|
|
|
|
LL | impl<'a, T> IntoIterator for &'a BitReaderWrapper<T>
|
|
| ^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^
|
|
LL | where
|
|
LL | &'a T: IntoIterator<Item = &'a u8>,
|
|
| ------------- unsatisfied trait bound introduced here
|
|
= note: 126 redundant requirements hidden
|
|
= note: required for `&BitReaderWrapper<BitReaderWrapper<BitReaderWrapper<...>>>` to implement `IntoIterator`
|
|
note: required by a bound in `Helper`
|
|
--> $DIR/inherent-bound-in-probe.rs:17:12
|
|
|
|
|
LL | struct Helper<'a, T>
|
|
| ------ required by a bound in this struct
|
|
LL | where
|
|
LL | &'a T: IntoIterator<Item = &'a u8>,
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Helper`
|
|
= note: the full name for the type has been written to '$TEST_BUILD_DIR/inherent-bound-in-probe.long-type-$LONG_TYPE_HASH.txt'
|
|
= note: consider using `--verbose` to print the full type name to the console
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
Some errors have detailed explanations: E0275, E0277.
|
|
For more information about an error, try `rustc --explain E0275`.
|