diff options
author | Zefram <zefram@fysh.org> | 2017-12-16 07:12:48 +0000 |
---|---|---|
committer | Zefram <zefram@fysh.org> | 2017-12-16 07:12:48 +0000 |
commit | 7347ee5481c77d2fdb023e0a1c19943d039ecc86 (patch) | |
tree | 33070b53fbf3d2c5c3408c580e3026b9b4e9e1d5 /perlio.c | |
parent | 64def2aeaeb63f92dadc6dfa33486c1d7b311963 (diff) | |
download | perl-7347ee5481c77d2fdb023e0a1c19943d039ecc86.tar.gz |
semicolon-friendly diagnostic control
New macros {GCC,CLANG}_DIAG_{IGNORE,RESTORE}_{DECL,STMT}, which take a
following semicolon. It is necessary to use the _DECL or _STMT version
as appropriate to the context. Fixes [perl #130726].
Diffstat (limited to 'perlio.c')
-rw-r--r-- | perlio.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -3584,9 +3584,9 @@ PerlIOStdio_set_ptrcnt(pTHX_ PerlIO *f, STDCHAR * ptr, SSize_t cnt) * - casting the LHS to (void*) -- totally unportable * * So let's try silencing the warning at least for gcc. */ - GCC_DIAG_IGNORE(-Wpointer-sign); + GCC_DIAG_IGNORE_STMT(-Wpointer-sign); PerlSIO_set_ptr(stdio, ptr); /* LHS STDCHAR* cast non-portable */ - GCC_DIAG_RESTORE; + GCC_DIAG_RESTORE_STMT; #ifdef STDIO_PTR_LVAL_SETS_CNT assert(PerlSIO_get_cnt(stdio) == (cnt)); #endif |