furix
cute os
include/types.h
729 bytes raw
1#ifndef FURIX_TYPES_H
2#define FURIX_TYPES_H
3
4typedef signed char int8_t;
5typedef unsigned char uint8_t;
6
7typedef signed short int16_t;
8typedef unsigned short uint16_t;
9
10typedef signed int int32_t;
11typedef unsigned int uint32_t;
12
13typedef signed long long int64_t;
14typedef unsigned long long uint64_t;
15
16_Static_assert(sizeof(uint8_t) == 1, "bad uint8_t");
17_Static_assert(sizeof(uint16_t) == 2, "bad uint16_t");
18_Static_assert(sizeof(uint32_t) == 4, "bad uint32_t");
19_Static_assert(sizeof(uint64_t) == 8, "bad uint64_t");
20
21typedef _Bool bool;
22#define true 1
23#define false 0
24
25#define offsetof(type, member) __builtin_offsetof(type, member)
26
27#define NULL ((void *)0)
28
29#endif /* FURIX_TYPES_H */