We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
derive
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Describe the bug Adding a generic type to a derive macro deletes all derives
To Reproduce
cat <<EOF | rustfmt #[derive(Debug, Foo<T>)] enum Bar{} EOF
This produces the following output, removing all derive attributes:
#[derive()] enum Bar {}
Expected behavior Something less nefarious, like rustc's
error: malformed `derive` attribute input
Meta
The text was updated successfully, but these errors were encountered:
Just noticed this as well:
#[derive(Debug, , Default)] struct Struct(i32);
turns into this:
#[derive()] struct Struct(i32);
which is bizarre when you're deleting one of the derives and you save partway through!
Sorry, something went wrong.
This has been fixed in source but not backported to a released version. Will try to do so for the upcoming 1.4.28 release
Closing as a duplicate of #3898, fix has been backported and will be in the next release
No branches or pull requests
Describe the bug
Adding a generic type to a derive macro deletes all derives
To Reproduce
This produces the following output, removing all derive attributes:
Expected behavior
Something less nefarious, like rustc's
Meta
The text was updated successfully, but these errors were encountered: