fixup _Generic macro usage

distinct macros failed (didn't realize). Was able to get proper setup with _Generic_L2 pattern
This commit is contained in:
ed
2025-02-12 00:19:04 -05:00
parent 90836817e9
commit d80a6b61da
16 changed files with 188 additions and 178 deletions
+6
View File
@@ -179,3 +179,9 @@
} \
while(0);
#endif
#define ct_if(expr, then, else) _Generic( \
(&(char[1 + !!(EXPR)]){0}), \
char (*)[2]: (THEN), \
char (*)[1]: (ELSE) \
)