Global: uses typed enums

This commit is contained in:
Carter Li
2026-07-10 16:35:46 +08:00
committed by 李通洲
parent f8908b9a36
commit 873454191f
32 changed files with 45 additions and 61 deletions
+1 -3
View File
@@ -2,7 +2,7 @@
#include "common/option.h"
typedef enum FF_A_PACKED FFPhysicalDiskType {
typedef enum FFPhysicalDiskType: uint8_t {
FF_PHYSICALDISK_TYPE_NONE = 0,
// If none is set, it's unknown
@@ -17,8 +17,6 @@ typedef enum FF_A_PACKED FFPhysicalDiskType {
FF_PHYSICALDISK_TYPE_READONLY = 1 << 6,
FF_PHYSICALDISK_TYPE_UNUSED = 1 << 7,
FF_PHYSICALDISK_TYPE_FORCE_UNSIGNED = UINT8_MAX,
} FFPhysicalDiskType;
static_assert(sizeof(FFPhysicalDiskType) == sizeof(uint8_t), "");