-
Notifications
You must be signed in to change notification settings - Fork 748
Allow specifying derive name #1301
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
The issue with this is that different derive(..) stuff have different requirements. Those requirements are encoded in |
I was suggesting hardcoding the the requirements for the default derives. Presumably user libraries are not going to replace them, or at least not commonly. |
you can use the custom derive API for this nowadays |
Dear Pvdrz, |
There's probably some overlap with this and other issues, but rather than having a derive() function for each derive, I'd just either let somebody specify it (
derive("PartialOrd")
) or specify multiple ones somehow (derive("Clone,Copy")
). This reduces the API size and increases functionality.There are some special cases where derivations automatically trigger other derivations, I'd either just make derive() a straight specification of exactly what you want to appear (this might allow for other things besides just names down the road, if that ever gets supported). Or go ahead and parse the list and automatically derive those things.
The text was updated successfully, but these errors were encountered: