-
Notifications
You must be signed in to change notification settings - Fork 532
Expand derive
documentation.
#540
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Send and Sync to my knowledge can't be derived -- they're auto-implemented by the compiler where applicable and are otherwise |
Oops, I had just copy/pasted from the code and didn't pay attention. |
Yes, the reference should strive to be the source of truth to which everything links, not the other way around. (caveat for things about rustc and notes...) The info should be here. |
We should also document:
|
The
derive
attribute documentation should probably list the built-in traits that are derivable. To my knowledge, the list is:Clone
Hash
PartialEq
Eq
PartialOrd
Ord
Debug
Default
Send
Sync
Copy
Should the documentation also specify the semantics of how the default implementations behave? It seems like important information, but I think it is mostly covered in the core/std docs. Another option is to link to https://doc.rust-lang.org/book/appendix-03-derivable-traits.html.
The text was updated successfully, but these errors were encountered: