1//! Run-time feature detection for the Rust standard library.
2//!
3//! To detect whether a feature is enabled in the system running the binary
4//! use one of the appropriate macro for the target:
5//!
6//! * `x86` and `x86_64`: [`is_x86_feature_detected`]
7//! * `arm`: [`is_arm_feature_detected`]
8//! * `aarch64`: [`is_aarch64_feature_detected`]
9//! * `riscv`: [`is_riscv_feature_detected`]
10//! * `mips`: [`is_mips_feature_detected`]
11//! * `mips64`: [`is_mips64_feature_detected`]
12//! * `powerpc`: [`is_powerpc_feature_detected`]
13//! * `powerpc64`: [`is_powerpc64_feature_detected`]
14
15#![unstable(feature = "stdsimd", issue = "27731")]
16#![feature(staged_api, stdsimd, doc_cfg, allow_internal_unstable)]
17#![deny(rust_2018_idioms)]
18#![allow(clippy::shadow_reuse)]
19#![deny(clippy::missing_inline_in_public_items)]
20#![cfg_attr(test, allow(unused_imports))]
21#![no_std]
22#![allow(internal_features)]
23
24#[cfg(test)]
25#[macro_use]
26extern crate std;
27
28// rust-lang/rust#83888: removing `extern crate` gives an error that `vec_spare>
29#[cfg_attr(feature = "std_detect_file_io", allow(unused_extern_crates))]
30#[cfg(feature = "std_detect_file_io")]
31extern crate alloc;
32
33#[doc(hidden)]
34#[unstable(feature = "stdsimd", issue = "27731")]
35pub mod detect;
36