diff options
author | Robby Zambito <contact@robbyzambito.me> | 2025-04-03 10:26:39 -0400 |
---|---|---|
committer | Robby Zambito <contact@robbyzambito.me> | 2025-04-03 10:28:48 -0400 |
commit | 5f939c37af256276a68ee9ca43c58a0d98730775 (patch) | |
tree | 3274d4afbdcb3172326e6e4fb5f95eacfd2dfd2b /src | |
parent | 322d0b3a528ac3760bee9e986649b39d1eaef38f (diff) |
Explicitly specify the size of connection options
This makes it so specifying the wrong number of options would actually throw a compile time error.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.zig b/src/main.zig index 5741b2d..cacd2fc 100644 --- a/src/main.zig +++ b/src/main.zig @@ -7,7 +7,7 @@ const SaprusPacketType = enum(u16) { connection = 0x00E9, }; -const SaprusConnectionOptions = packed struct { +const SaprusConnectionOptions = packed struct(u8) { opt1: bool = false, opt2: bool = false, opt3: bool = false, |