The version 2 change log states that the RapidHasher in the fast, quality and inner modules can change behavior upon version bump. For users who need stable output they are encouraged to use the v1, v2 and v3 modules. Yet, there is no struct in those modules that implement the Hasher trait. They have to serialize everything into bytes before calling the hash function.
I see that rapidhash::inner::RapidHasher already contains 4 parameters. I wonder is it possible to add one more parameter of the algorithm version, so that users who need stable hash output and Hasher trait can use it. I imagine the parameter can take an enum with the following values: v1, v2, v3, latest (current behavior).
The version 2 change log states that the
RapidHasherin thefast,qualityandinnermodules can change behavior upon version bump. For users who need stable output they are encouraged to use thev1,v2andv3modules. Yet, there is no struct in those modules that implement theHashertrait. They have to serialize everything into bytes before calling the hash function.I see that
rapidhash::inner::RapidHasheralready contains 4 parameters. I wonder is it possible to add one more parameter of the algorithm version, so that users who need stable hash output andHashertrait can use it. I imagine the parameter can take an enum with the following values:v1, v2, v3, latest (current behavior).