Skip to content

Support Hasher trait for the stable versions #32

@CrendKing

Description

@CrendKing

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).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions