We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 01ee02f commit 5225b7cCopy full SHA for 5225b7c
cpuid-bool/src/lib.rs
@@ -1,13 +1,14 @@
1
//! Macro for checking CPU capabilities at runtime.
2
//!
3
-//! # Usage example
+//! # Example
4
//! ```
5
+//! // This macro creates `cpuid_aes_sha` module
6
//! cpuid_bool::new!(cpuid_aes_sha, "aes", "sha");
7
8
//! // `token` is a Zero Sized Type value, which guarantees
9
//! // that underlying static storage got properly initialized,
10
//! // which allows to omit initialization branch
-//! let token = cpuid_aes_sha::init();
11
+//! let token: cpuid_aes_sha::InitToken = cpuid_aes_sha::init();
12
//! if token.get() {
13
//! println!("CPU supports both SHA and AES extensions");
14
//! } else {
0 commit comments