src/hotspot/share/utilities/compilerWarnings_gcc.hpp
changeset 58682 9f5b92d5a1b2
parent 53645 2c6c0fabe6a2
--- a/src/hotspot/share/utilities/compilerWarnings_gcc.hpp	Thu Oct 17 22:41:36 2019 +0200
+++ b/src/hotspot/share/utilities/compilerWarnings_gcc.hpp	Fri Oct 18 09:57:20 2019 +0900
@@ -50,6 +50,12 @@
 
 #define PRAGMA_FORMAT_IGNORED PRAGMA_DISABLE_GCC_WARNING("-Wformat")
 
+// Disable -Wstringop-truncation which is introduced in GCC 8.
+// https://gcc.gnu.org/gcc-8/changes.html
+#if !defined(__clang_major__) && (__GNUC__ >= 8)
+#define PRAGMA_STRINGOP_TRUNCATION_IGNORED PRAGMA_DISABLE_GCC_WARNING("-Wstringop-truncation")
+#endif
+
 #if defined(__clang_major__) && \
       (__clang_major__ >= 4 || \
       (__clang_major__ >= 3 && __clang_minor__ >= 1)) || \