rust-lang / rustc-stable-hash

A stable hashing algorithm used by rustc: cross-platform, deterministic, not secure
Apache License 2.0
5 stars 3 forks source link

Bootstrap the `rustc-stable-hash` crate #1

Closed Urgau closed 3 months ago

Urgau commented 4 months ago

This PR create the rustc-stable-hash crate and import the StableHasher (struct), StableHasherResult (trait) and SipHasher128 (struct) from rustc_data_structures along with their respective tests. All of those should be removed from rustc when it starts using this crate.

This PR also setup a very minimal CI (copied from rustc-hash), it will need to more coverage, it particular of big endian targets.

Also well as importing the Code of Conduct and licenses files.

r? @WaffleLapkin

michaelwoerister commented 4 months ago

Has this been discussed somewhere? I think extracting something into a separate repo warrants an MCP, if just for visibility.

Urgau commented 4 months ago

@michaelwoerister There was the team PR https://github.com/rust-lang/team/pull/1472, but apart from that, not really. Only some private discussions. As asked I created an MCP, https://github.com/rust-lang/compiler-team/issues/755.

michaelwoerister commented 4 months ago

Thanks, @Urgau!

fbstj commented 4 months ago

stupid question: does this repository need to have the history of the existing impl from rust-lang/rust imported? or at least mabye linked to (like "this is a copy of [this hash] in rust-lang/rust" somehow?