Files
externals/linux/include/ActivBoost/concept/assert.hpp
T
2023-12-15 13:15:08 -05:00

46 lines
1.9 KiB
C++

// Copyright David Abrahams 2006. Distributed under the Boost
// Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#ifndef ACTIV_BOOST_CONCEPT_ASSERT_DWA2006430_HPP
# define ACTIV_BOOST_CONCEPT_ASSERT_DWA2006430_HPP
# include <ActivBoost/config.hpp>
# include <ActivBoost/config/workaround.hpp>
// The old protocol used a constraints() member function in concept
// checking classes. If the compiler supports SFINAE, we can detect
// that function and seamlessly support the old concept checking
// classes. In this release, backward compatibility with the old
// concept checking classes is enabled by default, where available.
// The old protocol is deprecated, though, and backward compatibility
// will no longer be the default in the next release.
# if !defined(ACTIV_BOOST_NO_OLD_CONCEPT_SUPPORT) \
&& !defined(ACTIV_BOOST_NO_SFINAE) \
\
&& !(ACTIV_BOOST_WORKAROUND(__GNUC__, == 3) && ACTIV_BOOST_WORKAROUND(__GNUC_MINOR__, < 4))
// Note: gcc-2.96 through 3.3.x have some SFINAE, but no ability to
// check for the presence of particularmember functions.
# define ACTIV_BOOST_OLD_CONCEPT_SUPPORT
# endif
# ifdef ACTIV_BOOST_MSVC
# include <ActivBoost/concept/detail/msvc.hpp>
# elif ACTIV_BOOST_WORKAROUND(ACTIV_BOOST_BORLANDC, ACTIV_BOOST_TESTED_AT(0x564))
# include <ActivBoost/concept/detail/borland.hpp>
# else
# include <ActivBoost/concept/detail/general.hpp>
# endif
// Usage, in class or function context:
//
// ACTIV_BOOST_CONCEPT_ASSERT((UnaryFunctionConcept<F,bool,int>));
//
# define ACTIV_BOOST_CONCEPT_ASSERT(ModelInParens) \
ACTIV_BOOST_CONCEPT_ASSERT_FN(void(*)ModelInParens)
#endif // ACTIV_BOOST_CONCEPT_ASSERT_DWA2006430_HPP