forked from boostorg/variant2
Disable failing constexpr tests on g++ 10.1
This commit is contained in:
@ -7,11 +7,8 @@
|
||||
// http://www.boost.org/LICENSE_1_0.txt
|
||||
|
||||
#include <boost/variant2/variant.hpp>
|
||||
#include <boost/core/lightweight_test.hpp>
|
||||
#include <boost/core/lightweight_test_trait.hpp>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
#include <string>
|
||||
#include <boost/config.hpp>
|
||||
#include <boost/config/workaround.hpp>
|
||||
|
||||
using namespace boost::variant2;
|
||||
|
||||
@ -108,9 +105,17 @@ int main()
|
||||
STATIC_ASSERT( v.index() == 4 );
|
||||
}
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_GCC, == 100100)
|
||||
|
||||
// no idea why this fails on g++ 10
|
||||
|
||||
#else
|
||||
|
||||
{
|
||||
constexpr variant<int, int, float, float, X, X> v( in_place_index_t<5>{}, 0, 0 );
|
||||
|
||||
STATIC_ASSERT( v.index() == 5 );
|
||||
}
|
||||
|
||||
#endif
|
||||
}
|
||||
|
@ -7,6 +7,8 @@
|
||||
// http://www.boost.org/LICENSE_1_0.txt
|
||||
|
||||
#include <boost/variant2/variant.hpp>
|
||||
#include <boost/config.hpp>
|
||||
#include <boost/config/workaround.hpp>
|
||||
|
||||
using namespace boost::variant2;
|
||||
|
||||
@ -100,6 +102,12 @@ int main()
|
||||
STATIC_ASSERT( holds_alternative<X>(v) );
|
||||
}
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_GCC, == 100100)
|
||||
|
||||
// no idea why this fails on g++ 10
|
||||
|
||||
#else
|
||||
|
||||
{
|
||||
constexpr variant<int, int, float, float, X> v( in_place_type_t<X>{}, 0, 0 );
|
||||
|
||||
@ -107,4 +115,6 @@ int main()
|
||||
|
||||
STATIC_ASSERT( holds_alternative<X>(v) );
|
||||
}
|
||||
|
||||
#endif
|
||||
}
|
||||
|
Reference in New Issue
Block a user