2
0
mirror of https://github.com/boostorg/variant.git synced 2026-01-19 04:42:16 +00:00

fix issues found by inspect tool

This commit is contained in:
Antony Polukhin
2021-04-26 21:44:35 +03:00
parent 95ddf424e5
commit d80cb48f02
6 changed files with 9 additions and 8 deletions

View File

@@ -59,7 +59,7 @@
#endif
// Define a compiler generic null pointer value
#if defined(BOOST_NO_NULLPTR)
#if defined(BOOST_NO_CXX11_NULLPTR)
#define BOOST_VARIANT_NULL 0
#else
#define BOOST_VARIANT_NULL nullptr

View File

@@ -102,7 +102,7 @@ public: // visitor interfaces
# if !BOOST_WORKAROUND(BOOST_BORLANDC, BOOST_TESTED_AT(0x0551))
# define BOOST_VARIANT_AUX_GET_EXPLICIT_TEMPLATE_TYPE(t)
# else
# if defined(BOOST_NO_NULLPTR)
# if defined(BOOST_NO_CXX11_NULLPTR)
# define BOOST_VARIANT_AUX_GET_EXPLICIT_TEMPLATE_TYPE(t) \
, t* = 0
# else

View File

@@ -135,7 +135,7 @@ public: // visitor interfaces
# if !BOOST_WORKAROUND(BOOST_BORLANDC, BOOST_TESTED_AT(0x0551))
# define BOOST_VARIANT_AUX_GET_EXPLICIT_TEMPLATE_TYPE(t)
# else
# if defined(BOOST_NO_NULLPTR)
# if defined(BOOST_NO_CXX11_NULLPTR)
# define BOOST_VARIANT_AUX_GET_EXPLICIT_TEMPLATE_TYPE(t) \
, t* = 0
# else

View File

@@ -82,7 +82,7 @@ struct is_static_visitor_impl
} // namespace detail
template< typename T > struct is_static_visitor
: public ::boost::integral_constant<bool,(::boost::detail::is_static_visitor_impl<T>::value)>
: public ::boost::integral_constant<bool,(::boost::detail::is_static_visitor_impl<T>::value)>
{
public:
BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_static_visitor,(T))

View File

@@ -13,7 +13,8 @@
#include <algorithm> // for std::swap
#include <sstream>
#include <iostream>
#include <assert.h>
#include <boost/assert.hpp>
#include "class_a.h"
@@ -22,7 +23,7 @@ using namespace std;
class_a::~class_a()
{
assert(self_p_ == this);
BOOST_ASSERT(self_p_ == this);
}
class_a::class_a(int n)

View File

@@ -28,8 +28,8 @@ template <typename T>
using basic_set_t = std::unordered_set<T, hash>;
using value_t = boost::make_recursive_variant<
int_t,
basic_set_t<boost::recursive_variant_>
int_t,
basic_set_t<boost::recursive_variant_>
>::type;
using set_t = basic_set_t<value_t>;