forked from boostorg/mp11
Use push_macro/pop_macro to guard against the macro I from <complex.h>. Fixes #88.
This commit is contained in:
@ -26,6 +26,11 @@
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma push_macro( "I" )
|
||||
# undef I
|
||||
#endif
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace mp11
|
||||
@ -1374,4 +1379,8 @@ template<class L, class S> using mp_join = mp_apply<mp_append, mp_intersperse<L,
|
||||
} // namespace mp11
|
||||
} // namespace boost
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma pop_macro( "I" )
|
||||
#endif
|
||||
|
||||
#endif // #ifndef BOOST_MP11_ALGORITHM_HPP_INCLUDED
|
||||
|
@ -12,6 +12,11 @@
|
||||
#include <boost/mp11/utility.hpp>
|
||||
#include <cstddef>
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma push_macro( "I" )
|
||||
# undef I
|
||||
#endif
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace mp11
|
||||
@ -108,4 +113,8 @@ template<class Q, class... T> using mp_bind_q = mp_bind<Q::template fn, T...>;
|
||||
} // namespace mp11
|
||||
} // namespace boost
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma pop_macro( "I" )
|
||||
#endif
|
||||
|
||||
#endif // #ifndef BOOST_MP11_BIND_HPP_INCLUDED
|
||||
|
@ -11,6 +11,11 @@
|
||||
#include <boost/mp11/version.hpp>
|
||||
#include <cstddef>
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma push_macro( "I" )
|
||||
# undef I
|
||||
#endif
|
||||
|
||||
#if defined(__has_builtin)
|
||||
# if __has_builtin(__make_integer_seq)
|
||||
# define BOOST_MP11_HAS_MAKE_INTEGER_SEQ
|
||||
@ -109,4 +114,8 @@ template<class... T> using index_sequence_for = make_integer_sequence<std::size_
|
||||
} // namespace mp11
|
||||
} // namespace boost
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma pop_macro( "I" )
|
||||
#endif
|
||||
|
||||
#endif // #ifndef BOOST_MP11_INTEGER_SEQUENCE_HPP_INCLUDED
|
||||
|
@ -13,6 +13,11 @@
|
||||
#include <type_traits>
|
||||
#include <cstddef>
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma push_macro( "I" )
|
||||
# undef I
|
||||
#endif
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace mp11
|
||||
@ -39,4 +44,8 @@ template<std::size_t N> using mp_size_t = std::integral_constant<std::size_t, N>
|
||||
} // namespace mp11
|
||||
} // namespace boost
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma pop_macro( "I" )
|
||||
#endif
|
||||
|
||||
#endif // #ifndef BOOST_MP11_INTEGRAL_HPP_INCLUDED
|
||||
|
@ -19,6 +19,11 @@
|
||||
#include <boost/mp11/detail/config.hpp>
|
||||
#include <type_traits>
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma push_macro( "I" )
|
||||
# undef I
|
||||
#endif
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace mp11
|
||||
@ -469,4 +474,8 @@ template<class L, class Q> using mp_transform_third_q = mp_transform_third<L, Q:
|
||||
} // namespace mp11
|
||||
} // namespace boost
|
||||
|
||||
#if defined(_MSC_VER) || defined(__GNUC__)
|
||||
# pragma pop_macro( "I" )
|
||||
#endif
|
||||
|
||||
#endif // #ifndef BOOST_MP11_LIST_HPP_INCLUDED
|
||||
|
Reference in New Issue
Block a user