Disable maybe-unitialized warning for boost headers using a pragma.

This commit is contained in:
Daniel Kirchner 2022-05-11 16:09:39 +02:00
parent cbf9a4f1ed
commit cf311e5780

View File

@ -29,7 +29,15 @@
#error "Unsupported Boost version. At least 1.65 required."
#endif
// TODO: do this only conditionally as soon as a boost version with gcc 12 support is released.
#if defined(__GNUC__) && !defined(__clang__) && (__GNUC__ >= 12)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
#include <boost/multiprecision/cpp_int.hpp>
#if defined(__GNUC__) && !defined(__clang__) && (__GNUC__ >= 12)
#pragma GCC diagnostic pop
#endif
#include <limits>