cartel_sqlite/engine/sys/
code.rs1#[derive(Clone, Copy, Debug, PartialEq, Eq)]
2#[repr(transparent)]
3pub struct Code(i32);
4
5impl Code {
6 pub const fn new(code: i32) -> Self {
7 Self(code)
8 }
9
10 pub const fn get(self) -> i32 {
11 self.0
12 }
13
14 pub const fn primary(self) -> i32 {
15 self.0 & 0xff
16 }
17}