From 324b66c553085c5e24c00a70e563beddc3beb89f Mon Sep 17 00:00:00 2001 From: Urgau Date: Thu, 23 May 2024 15:20:25 +0200 Subject: [PATCH] Expect any feature cfg in core and std crates --- library/core/Cargo.toml | 4 +++- library/std/Cargo.toml | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/library/core/Cargo.toml b/library/core/Cargo.toml index daf2612833dd..0c2642341235 100644 --- a/library/core/Cargo.toml +++ b/library/core/Cargo.toml @@ -46,6 +46,8 @@ check-cfg = [ 'cfg(bootstrap)', 'cfg(no_fp_fmt_parse)', 'cfg(stdarch_intel_sde)', - # This matches `EXTRA_CHECK_CFGS` in `src/bootstrap/src/lib.rs`. + # core use #[path] imports to portable-simd `core_simd` crate + # and to stdarch `core_arch` crate which messes-up with Cargo list + # of declared features, we therefor expect any feature cfg 'cfg(feature, values(any()))', ] diff --git a/library/std/Cargo.toml b/library/std/Cargo.toml index 4b8ee4c13091..4b9e827247e7 100644 --- a/library/std/Cargo.toml +++ b/library/std/Cargo.toml @@ -105,5 +105,8 @@ check-cfg = [ 'cfg(backtrace_in_libstd)', 'cfg(netbsd10)', 'cfg(target_arch, values("xtensa"))', - 'cfg(feature, values("std", "as_crate"))', + # std use #[path] imports to portable-simd `std_float` crate + # and to the `backtrace` crate which messes-up with Cargo list + # of declared features, we therefor expect any feature cfg + 'cfg(feature, values(any()))', ]