Make `#[derive(Copy)]` enough for both `Clone` and `Copy`
HKalbasi:
It seems doesn't work in all cases though, e.g. with a generic parameter I see this:
Your proposal won't be able to support this case anyway, it is impossible without specialization. Unless you constrain Clone to T: Copy, but this significantly changes behavior and not something you can do if you want your proposal to be drop-in.
HKalbasi:
I meant dropping the original
#[rustc_ignore_this_impl_in_case_of_conflict]proposal and doing this only over an edition. That is,#[derive(Copy)]in a new edition is equivalent of bothCloneandCopy, and adding anotherCloneimpl (either manually or viaderive) is a hard error, and not touching the current editions at all.
That does not matter, since the only edition still need to be supported, and the code for it must still be inside the compiler.
Discussion in the ATmosphere