Closed xfbs closed 1 year ago
I'm curious, what's the use case? Why would you be comparing engine instances, or using them as map keys? Or using Debug to see their internal lookup tables, etc?
It would be nice to be able to store a dynamically selected engine in a cloneable struct.
Though the more general argument is that foreseeing all use cases is impossible and Rust does not allow implementing traits in depending crates: https://rust-lang.github.io/api-guidelines/interoperability.html#c-common-traits
I see, I can buy that. Is it just that you want Debug to exist at all, and the derived (likely verbose and not hat helpful) impl is okay? Or you want Debug to show something in particular?
The derived impl is fine, and it can always be changed later because Debug is explicitly not stable.
And yeah, in many cases it's important for a trait impl to just exist at all because that allows using the type in other types that derive the trait.
Traits are additive, having more of them implemented is almost always good.
I'll release a new version with the fix soon.
0.21.5 released with this fix.
The problem
GeneralPurpose
engine should implement some common traits. Definitely needed areClone
andDebug
, optionally good would bePartialEq
,Hash
, and some others.How I, the issue filer, am going to help solve it