derive_more
derive_more copied to clipboard
Feature idea: `PartialEq` and `PartialOrd` for the wrapped type
I'm finding myself needing to wrap a type "quickly", but then I don't want to have any specific restrictions on the inner-type, other than being wrapped.
PartialOrd
and PartialEq
where Rhs = InnerType
is a small ergonomic advantage if at all possible?
I see that #51 was shortly dismissed, but maybe this is a good time to maybe revisit this.
I have also been thinking if this is possible to add through a trait, but I think this is less explicit then what can be done using a derive-macro. Also the object-safety issue comes up if I want to do that..
Maybe it's indeed time to revisit, what do you think @tyranron?
@JelteF I do actually think that all the standard derives should be represented in derive_more
too, just because standard derives are very stupid regarding bounding type parameters. So, it's something definitely to have after going 1.0.