]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - common.h
sys: work around incomplete POSIX support in MacOS
[xonotic/darkplaces.git] / common.h
index 5b73aa6f6c4d9a5e0fd0bff5a21eac16c87ad24a..cde830dcfdc7e51fac232f75fee227459d8cfbcd 100644 (file)
--- a/common.h
+++ b/common.h
@@ -221,7 +221,12 @@ void COM_Shutdown (void);
 char *va(char *buf, size_t buflen, const char *format, ...) DP_FUNC_PRINTF(3);
 // does a varargs printf into provided buffer, returns buffer (so it can be called in-line unlike dpsnprintf)
 
-// GCC with -Werror=c++-compat will error out if static_assert is used even though the macro is valid C11...
+/* Some versions of GCC with -Wc++-compat will complain if static_assert
+ * is used even though the macro is valid C11, so make it happy anyway
+ * because having build logs without any purple text is pretty satisfying.
+ * TODO: Disable the flag by default in makefile, with an optional variable
+ * to reenable it.
+ */
 #ifndef __cplusplus
 #define DP_STATIC_ASSERT(expr, str) _Static_assert(expr, str)
 #else