rs-merkle icon indicating copy to clipboard operation
rs-merkle copied to clipboard

Dynamic hash algorithm support

Open sinui0 opened this issue 7 months ago • 1 comments

Hi, we're currently enjoying using this crate in our project. However, we're now looking to allow users to provide their own hash algorithms which are plugged in with dynamic dispatch. The Hasher trait is intended to be implemented on ZSTs, thus has no access to runtime information.

From the look of it changing Hasher to receive &self would be a relatively large change, although it may be possible to avoid breaking changes by adding new traits and further encapsulating some of the inner functionality. I'll just start with posing this issue, what do you think? I can contribute to this effort if desired.

sinui0 avatar Jul 30 '24 08:07 sinui0