forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit7b5dec7
committed
perl: Hide warnings inside perl.h when using gcc compatible compiler
New versions of perl trigger warnings within perl.h with our compilerflags. At least -Wdeclaration-after-statement, -Wshadow=compatible-local areknown to be problematic.To avoid these warnings, conditionally use #pragma GCC system_header beforeincluding plperl.h.Alternatively, we could add the include paths for problematic headers with-isystem, but that is a larger hammer and is harder to search for.A more granular alternative would be to use #pragma GCC diagnosticpush/ignored/pop, but gcc warns about unknown warnings being ignored, so everyto-be-ignored-temporarily compiler warning would require its own pg_config.hsymbol and #ifdef.As the warnings are voluminous, it makes sense to backpatch this change. Butdon't do so yet, we first want gather buildfarm coverage - it's e.g. possiblethat some compiler claiming to be gcc compatible has issues with the pragma.Author: Andres Freund <andres@anarazel.de>Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>Discussion: Discussion:https://postgr.es/m/20221228182455.hfdwd22zztvkojy2@awork3.anarazel.de1 parenta02740e commit7b5dec7
2 files changed
+37
-0
lines changedLines changed: 28 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
360 | 360 |
| |
361 | 361 |
| |
362 | 362 |
| |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
363 | 391 |
| |
364 | 392 |
| |
365 | 393 |
| |
|
Lines changed: 9 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
70 | 70 |
| |
71 | 71 |
| |
72 | 72 |
| |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
73 | 82 |
| |
74 | 83 |
| |
75 | 84 |
| |
|
0 commit comments
Comments
(0)