From 59e9940d5b824c315a80d2c3446ca810743d4fd9 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Mon, 27 Jan 2025 19:38:14 +0200 Subject: [PATCH] Suppress false -Warray-bounds positive with -fsanitize=undefined --- test/array6.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/test/array6.cpp b/test/array6.cpp index 3f3f5b0..65b8d47 100644 --- a/test/array6.cpp +++ b/test/array6.cpp @@ -7,12 +7,18 @@ #define BOOST_ALLOW_DEPRECATED_SYMBOLS // get_c_array +#include +#include +#include #include #include -#include #include -#include +#if defined(BOOST_GCC) && BOOST_GCC / 10000 == 13 +// false -Warray-bounds positive when using -fsanitize=undefined +// restricted to GCC 13 because that's what is tested on Drone +# pragma GCC diagnostic ignored "-Warray-bounds" +#endif namespace { template< class T >