File tree Expand file tree Collapse file tree 2 files changed +1
-23
lines changed Expand file tree Collapse file tree 2 files changed +1
-23
lines changed Original file line number Diff line number Diff line change 13
13
* .pdb
14
14
* .exe
15
15
* vgcore
16
- .gdb_history
16
+ * .gdb_history
17
17
.vs /
18
18
.xmake /
19
19
.cache /
20
20
objs /
21
21
build /
22
- example /.gdb_history
23
22
example /Test
Original file line number Diff line number Diff line change 172
172
static_assert (sizeof (uint16_t ) == 2, "uint16_t is not of the correct size");
173
173
static_assert (sizeof (uint32_t ) == 4, "uint32_t is not of the correct size");
174
174
static_assert (sizeof (uint64_t ) == 8, "uint64_t is not of the correct size");
175
- #elif defined(MLX_COMPILER_GCC)
176
- #define STATIC_ASSERT (cnd, descr ) \
177
- ({ \
178
- extern int __attribute__ ((error (" static assert failed: (" #cnd " ) (" #descr " )" ))) compile_time_check (void ); \
179
- ((cnd) ? 0 : compile_time_check ()), 0 ; \
180
- })
181
-
182
- #include < limits.h>
183
- #include < stdint.h>
184
-
185
- STATIC_ASSERT (CHAR_BIT == 8 , " CHAR_BIT is expected to be 8" );
186
-
187
- STATIC_ASSERT (sizeof (int8_t ) == 1, "int8_t is not of the correct size" );
188
- STATIC_ASSERT (sizeof (int16_t ) == 2, "int16_t is not of the correct size");
189
- STATIC_ASSERT (sizeof (int32_t ) == 4, "int32_t is not of the correct size");
190
- STATIC_ASSERT (sizeof (int64_t ) == 8, "int64_t is not of the correct size");
191
-
192
- STATIC_ASSERT (sizeof (uint8_t ) == 1, "uint8_t is not of the correct size" );
193
- STATIC_ASSERT (sizeof (uint16_t ) == 2, "uint16_t is not of the correct size");
194
- STATIC_ASSERT (sizeof (uint32_t ) == 4, "uint32_t is not of the correct size");
195
- STATIC_ASSERT (sizeof (uint64_t ) == 8, "uint64_t is not of the correct size");
196
175
#else
197
176
#define STATIC_ASSERT (COND, MSG ) typedef char static_assertion___##MSG[(COND)?1 :-1 ]
198
177
You can’t perform that action at this time.
0 commit comments