mirror of
https://github.com/wichtounet/thor-os.git
synced 2025-09-18 09:04:49 -04:00
add size_t typedef
This commit is contained in:
parent
32b715723b
commit
79ba19fa8a
@ -15,11 +15,13 @@ typedef unsigned int uint32_t __attribute__ ((__mode__ (__SI__)));
|
||||
typedef unsigned int uint64_t __attribute__ ((__mode__ (__DI__)));
|
||||
|
||||
typedef uint64_t uintptr_t;
|
||||
typedef uint64_t size_t;
|
||||
|
||||
static_assert(sizeof(uint8_t) == 1, "uint32_t must be 1 byte long");
|
||||
static_assert(sizeof(uint16_t) == 2, "uint32_t must be 2 bytes long");
|
||||
static_assert(sizeof(uint32_t) == 4, "uint32_t must be 4 bytes long");
|
||||
static_assert(sizeof(uint64_t) == 8, "uint64_t must be 8 bytes long");
|
||||
static_assert(sizeof(size_t) == 8, "size_t must be 8 bytes long");
|
||||
static_assert(sizeof(uintptr_t) == sizeof(uint64_t*), "uintptr_t must have the same size as a pointer");
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user