]> git.lizzy.rs Git - rust.git/blob - tests/ui/traits/copy-impl-cannot-normalize.stderr
Auto merge of #107137 - Mark-Simulacrum:169, r=Mark-Simulacrum
[rust.git] / tests / ui / traits / copy-impl-cannot-normalize.stderr
1 error[E0277]: the trait bound `T: TraitFoo` is not satisfied
2   --> $DIR/copy-impl-cannot-normalize.rs:22:18
3    |
4 LL | impl<T> Copy for Foo<T> {}
5    |                  ^^^^^^ the trait `TraitFoo` is not implemented for `T`
6    |
7 note: required for `Foo<T>` to implement `Clone`
8   --> $DIR/copy-impl-cannot-normalize.rs:12:9
9    |
10 LL | impl<T> Clone for Foo<T>
11    |         ^^^^^     ^^^^^^
12 LL | where
13 LL |     T: TraitFoo,
14    |        -------- unsatisfied trait bound introduced here
15 note: required by a bound in `Copy`
16   --> $SRC_DIR/core/src/marker.rs:LL:COL
17 help: consider restricting type parameter `T`
18    |
19 LL | impl<T: TraitFoo> Copy for Foo<T> {}
20    |       ++++++++++
21
22 error: aborting due to previous error
23
24 For more information about this error, try `rustc --explain E0277`.