mirror of
https://github.com/openjdk/jdk.git
synced 2026-03-26 07:40:09 +00:00
8288101: False build warning-as-error with GCC 9 after JDK-8214976
Reviewed-by: mdoerr, zgu, kbarrett
This commit is contained in:
parent
0164145afc
commit
d9c1364dde
@ -69,10 +69,13 @@
|
||||
|
||||
#endif // clang/gcc version check
|
||||
|
||||
#if (__GNUC__ >= 9) || (defined(__clang_major__) && (__clang_major__ >= 14))
|
||||
#if (__GNUC__ >= 10) || (defined(__clang_major__) && (__clang_major__ >= 14))
|
||||
|
||||
// Use "warning" attribute to detect uses of "forbidden" functions.
|
||||
//
|
||||
// Note: The warning attribute is available since GCC 9, but disabling pragmas
|
||||
// does not work reliably in ALLOW_C_FUNCTION. GCC 10+ and up work fine.
|
||||
//
|
||||
// Note: _FORTIFY_SOURCE transforms calls to certain functions into calls to
|
||||
// associated "checking" functions, and that transformation seems to occur
|
||||
// *before* the attribute check. We use fortification in fastdebug builds,
|
||||
@ -89,6 +92,6 @@
|
||||
__VA_ARGS__ \
|
||||
PRAGMA_DIAG_POP
|
||||
|
||||
#endif // gcc9+ or clang14+
|
||||
#endif // gcc10+ or clang14+
|
||||
|
||||
#endif // SHARE_UTILITIES_COMPILERWARNINGS_GCC_HPP
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user