tkaitchuck / aHash

aHash is a non-cryptographic hashing algorithm that uses the AES hardware instruction
https://crates.io/crates/ahash
Apache License 2.0
986 stars 94 forks source link

Require Cargo feature opt-in for `min_specialize` #239

Open alexcrichton opened 1 week ago

alexcrichton commented 1 week ago

This commit switches away from implicitly enabling the min_specialize Rust nightly feature whenever a Nightly compiler is used to instead requiring an explicit opt-in with a new Cargo feature nightly-specialize. The goal of this commit is to fix #238 and has two primary motivations:

  1. In #238 I'm trying to build something that depends on this crate as part of the Rust bootstrap process but this crate fails to build due to min_specialize not being allowed but a nightly compiler is in use. This is due to the fact that the way -Zallow-features is managed in the bootstrap is different than the standard Cargo way of doing so.

  2. This removes a failure mode where if one day the min_specialize feature changes this crate won't break when built on nightly. Users of Nightly compilers will be able to continue using this crate if the feature was not explicitly opted-in to.