You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Compiling the above code generates the following error:
phantom /tmp $ rustc test.rs
test.rs:7:1: 7:22 error: the trait `Copy` may not be implemented for this type; variant `MyVariant` does not implement `Copy`
test.rs:7 impl Copy for Test {}
^~~~~~~~~~~~~~~~~~~~~
error: aborting due to previous error
The error mentions that MyVariant doesn't implement Copy without pointing to the right type in the constructor that is actually missing the implementation NoCopy.