about summary refs log tree commit diff
path: root/library/stdarch/crates/std_detect/src/detect/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'library/stdarch/crates/std_detect/src/detect/mod.rs')
-rw-r--r--library/stdarch/crates/std_detect/src/detect/mod.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/library/stdarch/crates/std_detect/src/detect/mod.rs b/library/stdarch/crates/std_detect/src/detect/mod.rs
index 80207daad8f..3e00c205547 100644
--- a/library/stdarch/crates/std_detect/src/detect/mod.rs
+++ b/library/stdarch/crates/std_detect/src/detect/mod.rs
@@ -90,4 +90,9 @@ cfg_if! {
         mod os;
     }
 }
-pub use self::os::check_for;
+
+/// Performs run-time feature detection.
+#[inline]
+pub fn check_for(x: Feature) -> bool {
+    cache::test(x as u32, self::os::detect_features)
+}