forked from kframework/c-semantics
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstdint.h
112 lines (87 loc) · 3.21 KB
/
stdint.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#ifndef _KCC_STDINT_H
#define _KCC_STDINT_H
#include <kcc_settings.h>
typedef signed char int8_t;
typedef unsigned char uint8_t;
# define INT8_MIN (-128)
# define INT8_MAX (127)
# define UINT8_MAX (255)
typedef signed short int16_t;
typedef unsigned short uint16_t;
# define INT16_MIN (-32767-1)
# define INT16_MAX (32767)
# define UINT16_MAX (65535)
typedef signed int int32_t;
typedef unsigned int uint32_t;
# define INT32_MIN (-2147483647-1)
# define INT32_MAX (2147483647)
# define UINT32_MAX (4294967295U)
typedef signed long long int64_t;
typedef unsigned long long uint64_t;
# define INT64_MIN (-9223372036854775807LL-1)
# define INT64_MAX (9223372036854775807LL)
# define UINT64_MAX (18446744073709551615ULL)
typedef signed char int_least8_t;
typedef unsigned char uint_least8_t;
# define INT_LEAST8_MIN (-128)
# define INT_LEAST8_MAX (127)
# define UINT_LEAST8_MAX (255)
typedef signed short int_least16_t;
typedef unsigned short uint_least16_t;
# define INT_LEAST16_MIN (-32767-1)
# define INT_LEAST16_MAX (32767)
# define UINT_LEAST16_MAX (65535)
typedef signed int int_least32_t;
typedef unsigned int uint_least32_t;
# define INT_LEAST32_MIN (-2147483647-1)
# define INT_LEAST32_MAX (2147483647)
# define UINT_LEAST32_MAX (4294967295U)
typedef signed long long int int_least64_t;
typedef unsigned long long int uint_least64_t;
# define INT_LEAST64_MIN (-9223372036854775807LL-1)
# define INT_LEAST64_MAX (9223372036854775807LL)
# define UINT_LEAST64_MAX (18446744073709551615ULL)
typedef signed char int_fast8_t;
typedef unsigned char uint_fast8_t;
# define INT_FAST8_MIN (-128)
# define INT_FAST8_MAX (127)
# define UINT_FAST8_MAX (255)
typedef signed short int_fast16_t;
typedef unsigned short uint_fast16_t;
# define INT_FAST16_MIN (-32767-1)
# define INT_FAST16_MAX (32767)
# define UINT_FAST16_MAX (65535)
typedef signed int int_fast32_t;
typedef unsigned int uint_fast32_t;
# define INT_FAST32_MIN (-2147483647-1)
# define INT_FAST32_MAX (2147483647)
# define UINT_FAST32_MAX (4294967295U)
typedef signed long long int int_fast64_t;
typedef unsigned long long int uint_fast64_t;
# define INT_FAST64_MIN (-9223372036854775807LL-1)
# define INT_FAST64_MAX (9223372036854775807LL)
# define UINT_FAST64_MAX (18446744073709551615ULL)
// intptr_t and uintptr_t are optional
typedef signed int intptr_t;
typedef unsigned int uintptr_t;
typedef signed long long int intmax_t;
typedef unsigned long long int uintmax_t;
# define INTMAX_MIN (-9223372036854775807LL-1)
# define INTMAX_MAX (9223372036854775807LL)
# define UINTMAX_MAX (18446744073709551615ULL)
# define PTRDIFF_MIN (-2147483647-1)
# define PTRDIFF_MAX (2147483647)
# define SIZE_MAX (4294967295U)
# define WCHAR_MIN (-2147483647-1)
# define WCHAR_MAX (2147483647)
# define INT8_C(value) ((int_least8_t) value)
# define INT16_C(value) ((int_least16_t) value)
# define INT32_C(value) ((int_least32_t) value)
# define INT64_C(value) ((int_least64_t) value)
# define UINT8_C(value) ((uint_least8_t) value)
# define UINT16_C(value) ((uint_least16_t) value)
# define UINT32_C(value) ((uint_least32_t) value)
# define UINT64_C(value) ((uint_least64_t) value)
# define INTMAX_C(value) ((intmax_t) value)
# define UINTMAX_C(value) ((uintmax_t) value)
#endif