Skip to content

Commit

Permalink
Leak full Wparentheses suppression for GCC 9
Browse files Browse the repository at this point in the history
Reported as an issue on Discord. I thought that by GCC 9, the
C++ frontend was fixed enough to support `_Pragma`-based
suppression correctly, but apparently I was wrong.
  • Loading branch information
horenmar committed May 31, 2022
1 parent 8c952bd commit cca5923
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/catch2/internal/catch_test_macro_impl.hpp
Expand Up @@ -14,9 +14,9 @@
#include <catch2/internal/catch_stringref.hpp>
#include <catch2/internal/catch_source_line_info.hpp>

// We need this suppression to leak, because it took until GCC 9
// We need this suppression to leak, because it took until GCC 10
// for the front end to handle local suppression via _Pragma properly
#if defined(__GNUC__) && !defined(__clang__) && !defined(__ICC) && __GNUC__ < 9
#if defined(__GNUC__) && !defined(__clang__) && !defined(__ICC) && __GNUC__ <= 9
#pragma GCC diagnostic ignored "-Wparentheses"
#endif

Expand Down

0 comments on commit cca5923

Please sign in to comment.