diff options
author | Jack O'Connor <oconnor663@gmail.com> | 2020-02-10 15:24:10 -0500 |
---|---|---|
committer | Jack O'Connor <oconnor663@gmail.com> | 2020-02-10 15:54:52 -0500 |
commit | e43a7d68bc5a708c5cede660c843eb613c7d0013 (patch) | |
tree | 3efd555839344676a1231080498ee550c110cd8b | |
parent | 0de44128848a7c8747e4bd1615b4569454758d99 (diff) |
avoid compiling avx512_detected() when the "c_avx512" feature is disabled
https://github.com/rust-lang/rust/issues/68905 is currently causing
nightly builds to fail, unless `--no-default-features` is used. This
change means that the default build will succeed, and the failure will
only happen when the "c_avx512" is enabled. The `b3sum` crate will still
fail to build on nightly, because it enables that feature, but most
callers should start succeeding on nightly.
-rw-r--r-- | src/platform.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/platform.rs b/src/platform.rs index abf9d30..b453a6e 100644 --- a/src/platform.rs +++ b/src/platform.rs @@ -252,6 +252,7 @@ impl Platform { // Note that AVX-512 is divided into multiple featuresets, and we use two of // them, F and VL. +#[cfg(feature = "c_avx512")] #[cfg(any(target_arch = "x86", target_arch = "x86_64"))] #[inline(always)] pub fn avx512_detected() -> bool { |