-
Couldn't load subscription status.
- Fork 962
Closed
Labels
C-feature-requestCategory: a feature request (not decided/implemented)Category: a feature request (not decided/implemented)
Description
I always try to keep derives in a certain order, so they are uniform with the rest of the crate. It would be nice if rustfmt could automatically sort them :)
I could imagine sorting them:
-
alphabetically:
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] -
after some sort of priority
I like the order in which the traits are listed in the rust-api-guidelines#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash, Debug, Display, Default)]I think they simply grouped similar traits together:
Copy+CloneEq+PartialEqOrd+PartialOrdDebug+Display
Lokathor, ndmitchell, jhpratt, 8573, ctaggart and 28 more
Metadata
Metadata
Assignees
Labels
C-feature-requestCategory: a feature request (not decided/implemented)Category: a feature request (not decided/implemented)