-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Document the traits that are #[derive]-able #29711
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
While it would be helpful to list them elsewhere, they are currently listed in the book: https://doc.rust-lang.org/nightly/book/traits.html#deriving. |
Note that nothing appears to prevent that list from going out of date. |
This limitation would be nice to get away from as well. I'm not sure if this has been discussed elsewhere. |
I think this is the right way to go to solve this issue, for sure. It's not in the reference because it's not really a language thing, and the restriction will go away eventually. |
in their API docs Fixes rust-lang#29711
in their API docs Fixes rust-lang#29711
Hi Rust !
Neither on the reference nor the doc of the trait itself inform us of the derivability of the standard traits.
It would be great to have the list of all the derivable traits in the Reference, and each trait could have a note in its doc saying that this trait is automagically derivable.
Also, it could be worth pointing some of the issues with deriving in the doc.
A quick search showed me some lifetimes error in some special cases, and performance issue for large enums. This is something that could be in the doc of the traits with these known issues using auto-deriving.
The text was updated successfully, but these errors were encountered: