From: Jonathan Wakely Date: Thu, 27 Feb 2020 17:22:50 +0000 (+0000) Subject: libstdc++: Fix failing test in debug mode X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=86e2dc22c91a722d2624c0010d81f1ce4b911bbd;p=gcc.git libstdc++: Fix failing test in debug mode This fixes a failure due to a (correct) warning seen when testing with -D_GLIBCXX_USE_CXX11_ABI=0 -D_GLIBCXX_ASSERTIONS: include/bits/char_traits.h:365: warning: 'void* __builtin_memcpy(void*, const void*, long unsigned int)' specified bound 18446744073709551615 exceeds maximum object size 9223372036854775807 [-Wstringop-overflow=] FAIL: 21_strings/basic_string/cons/char/1.cc (test for excess errors) * testsuite/21_strings/basic_string/cons/char/1.cc: Disable -Wstringop-overflow warnings. --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 26e288d4f43..24ce2a140db 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2020-02-28 Jonathan Wakely + + * testsuite/21_strings/basic_string/cons/char/1.cc: Disable + -Wstringop-overflow warnings. + 2020-02-27 Jonathan Wakely * testsuite/lib/libstdc++.exp (v3_target_compile): Add diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/cons/char/1.cc b/libstdc++-v3/testsuite/21_strings/basic_string/cons/char/1.cc index 66054588273..1c3e43f2fd4 100644 --- a/libstdc++-v3/testsuite/21_strings/basic_string/cons/char/1.cc +++ b/libstdc++-v3/testsuite/21_strings/basic_string/cons/char/1.cc @@ -19,6 +19,8 @@ // 21.3.1 basic_string constructors. +// { dg-options "-Wno-stringop-overflow" } + #include #include #include