Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/aienux/blob/main/vendor/bitflags/src/external/bytemuck.rs # aienux Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `aienux / vendor / bitflags / src / external / bytemuck.rs` 19 lines ยท 399 bytes Raw Blame History 1 #[cfg(test)] 2 mod tests { 3 use bytemuck::{Pod, Zeroable}; 4 5 bitflags! { 6 #[derive(Pod, Zeroable, Clone, Copy)] 7 #[repr(transparent)] 8 struct Color: u32 { 9 const RED = 0x1; 10 const GREEN = 0x2; 11 const BLUE = 0x4; 12 } 13 } 14 15 #[test] 16 fn test_bytemuck() { 17 assert_eq!(0x1, bytemuck::cast::(Color::RED)); 18 } 19 }