3 releases
0.1.2 | Jan 28, 2021 |
---|---|
0.1.1 | Jan 28, 2021 |
0.1.0 | Jan 28, 2021 |
#1594 in Algorithms
2KB
cc4
Implementation of four_cc in Rust as a const fn
. Supports both little and big endian systems.
four_cc(b"code");
Since four_cc
is a const fn
, you can also use it to define enum
values for enums
represented by u32
.
#[repr(u32)]
pub enum Id {
Apple = four_cc(b"appl"),
}