Fix push/pop mismatch
Without this, perlhead.swg does `#pragma GCC diagnostic pop` if `__GNUC__ >= 10` - without any prior `#pragma GCC diagnostic push`. There's also a mismatch between the conditions that trigger `#pragma GCC diagnostic ignored` (where the `push` should be) and the attempt to `#pragma GCC diagnostic pop`.
This commit is contained in:
parent
60af317956
commit
8ece583aa0
2 changed files with 6 additions and 0 deletions
|
|
@ -7,6 +7,7 @@ extern "C" {
|
|||
|
||||
#if __GNUC__ >= 10
|
||||
#if defined(__cplusplus)
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wvolatile"
|
||||
#endif
|
||||
#endif
|
||||
|
|
@ -16,8 +17,10 @@ extern "C" {
|
|||
#include "XSUB.h"
|
||||
|
||||
#if __GNUC__ >= 10
|
||||
#if defined(__cplusplus)
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* PERL_REVISION was added in Perl 5.6. */
|
||||
#if !defined PERL_REVISION || (PERL_REVISION-0 == 5 && PERL_VERSION-0 < 8)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue