RustCrypto: CPU bits selection
Compile-time detection heuristics for the optimal word size to use for the
target CPU, which in some cases may differ from its address size a.k.a.
target_pointer_width.
Implemented as macro_rules!.
Below is a basic example of how you can use the cpubits! macro:
cpubits::cpubits! {
16 => { pub type Word = u16; }
32 => { pub type Word = u32; }
64 => { pub type Word = u64; }
}Licensed under either of:
at your option.
Includes portions from the cfg-if crate, which are also dual-licensed Apache 2.0 + MIT.
Copyright (c) 2014 Alex Crichton.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.