On 9/17/2020 10:48 PM, Gavin Lambert via Boost wrote:
On 18/09/2020 13:07, Edward Diener wrote:
I tried:
#pragma GCC diagnostic ignore "-Wpedantic"
or
#pragma GCC diagnostic warning "-Wpedantic"
and neither does anything.
-Wpedantic isn't a thing; you need to name the specific individual warnings that actually occur. These names should be included in the compiler output.
https://gcc.gnu.org/onlinedocs/gcc/Diagnostic-Pragmas.html#Diagnostic-Pragma...
And as Andrey noted, to do this properly you'd need to push/pop the warning status to avoid affecting the rest of the translation unit, including user code.
(This means that at best you can only disable warnings for internal usage, not for user usage. But that's as it should be. And you should verify that whatever you do *doesn't* hide the warnings in user code, otherwise you're just creating a different kind of problem.)