Skip to content

Commit 773927a

Browse files
authored
Update ast.c
For the sake of completeness
1 parent 0e1681a commit 773927a

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

src/AST/ast.c

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,24 @@ void ast_init(ast_t *ast, unsigned int cross_compile_for){
218218
#endif
219219
);
220220

221+
// __cygwin__
222+
meta_definition_add_bool(&ast->meta_definitions, &ast->meta_definitions_length, &ast->meta_definitions_capacity, "__cygwin__",
223+
#ifdef __CYGWIN__
224+
cross_compile_for == CROSS_COMPILE_NONE
225+
#else
226+
false
227+
#endif
228+
);
229+
230+
// __msys__
231+
meta_definition_add_bool(&ast->meta_definitions, &ast->meta_definitions_length, &ast->meta_definitions_capacity, "__msys__",
232+
#ifdef __MSYS__
233+
cross_compile_for == CROSS_COMPILE_NONE
234+
#else
235+
false
236+
#endif
237+
);
238+
221239
unsigned short x = 0xEEFF;
222240
if (*((unsigned char*) &x) == 0xFF || cross_compile_for == CROSS_COMPILE_WINDOWS){
223241
// Little Endian

0 commit comments

Comments
 (0)