fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0599]: the method `clone` exists for struct `Foo<NonCopy>`, but its trait bounds were not satisfied 2 --> $DIR/deriving-with-repr-packed-2.rs:18:11 3 | 4LL | pub struct Foo<T>(T, T, T); 5 | ----------------- 6 | | 7 | method `clone` not found for this struct 8 | doesn't satisfy `Foo<NonCopy>: Clone` 9LL | 10LL | struct NonCopy; 11 | -------------- 12 | | 13 | doesn't satisfy `NonCopy: Clone` 14 | doesn't satisfy `NonCopy: Copy` 15... 16LL | _ = x.clone(); 17 | ^^^^^ method cannot be called on `Foo<NonCopy>` due to unsatisfied trait bounds 18 | 19note: the following trait bounds were not satisfied: 20 `NonCopy: Clone` 21 `NonCopy: Copy` 22 --> $DIR/deriving-with-repr-packed-2.rs:5:16 23 | 24LL | #[derive(Copy, Clone, Default, PartialEq, Eq)] 25 | ^^^^^ unsatisfied trait bound introduced in this `derive` macro 26help: consider annotating `NonCopy` with `#[derive(Clone, Copy)]` 27 | 28LL + #[derive(Clone, Copy)] 29LL | struct NonCopy; 30 | 31 32error: aborting due to previous error 33 34For more information about this error, try `rustc --explain E0599`.