forked from boostorg/intrusive
DIsable "-Warray-bounds" for GCC-12 due to false positives
This commit is contained in:
@@ -12,7 +12,13 @@
|
|||||||
#ifndef BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
#ifndef BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
||||||
#define BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
#define BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
||||||
|
|
||||||
#include <boost/functional/hash/hash.hpp>
|
#include <boost/container_hash/hash.hpp>
|
||||||
|
|
||||||
|
//GCC has some false array_bounds warnings starting in GCC 12
|
||||||
|
#if defined(BOOST_CLANG) || (defined(BOOST_GCC) && (BOOST_GCC >= 120000))
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Warray-bounds"
|
||||||
|
#endif
|
||||||
|
|
||||||
struct int_holder
|
struct int_holder
|
||||||
{
|
{
|
||||||
@@ -108,4 +114,9 @@ struct int_priority_of_value
|
|||||||
{ return tv.int_value(); }
|
{ return tv.int_value(); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
//GCC has some false array_bounds warnings starting in GCC 12
|
||||||
|
#if defined(BOOST_CLANG) || (defined(BOOST_GCC) && (BOOST_GCC >= 120000))
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif //BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
#endif //BOOST_INTRUSIVE_DETAIL_INT_HOLDER_HPP
|
||||||
|
Reference in New Issue
Block a user