Fix warning on clang and old gcc
This commit is contained in:
1 parent
c625c39883
commit
8597b0b8c0
1 file changed
+1
-1
+1
-1
@@ -627,7 +627,7 @@ static void test_M_CSTR(void)
|
|||||||
_Pragma("GCC diagnostic ignored \"-Wformat-truncation\"")
|
_Pragma("GCC diagnostic ignored \"-Wformat-truncation\"")
|
||||||
#endif
|
#endif
|
||||||
r = strcmp(M_CSTR("Hello %s %c", "World", '!'), "Hello W");
|
r = strcmp(M_CSTR("Hello %s %c", "World", '!'), "Hello W");
|
||||||
#ifdef __GNUC__
|
#if defined(__GNUC__) && __GNUC__ >= 7 && !defined(__clang__)
|
||||||
_Pragma("GCC diagnostic pop")
|
_Pragma("GCC diagnostic pop")
|
||||||
#endif
|
#endif
|
||||||
assert (r == 0);
|
assert (r == 0);
|
||||||
|
|||||||
Reference in new issue
Block a user