File indexing completed on 2025-12-16 09:44:40
0001
0002
0003
0004 #ifndef BOOST_CONCEPT_CHECK_MSVC_DWA2006429_HPP
0005 # define BOOST_CONCEPT_CHECK_MSVC_DWA2006429_HPP
0006
0007 # ifdef BOOST_OLD_CONCEPT_SUPPORT
0008 # include <boost/concept_check/has_constraints.hpp>
0009 # include <boost/type_traits/conditional.hpp>
0010 # endif
0011
0012
0013
0014
0015
0016
0017
0018 namespace boost
0019 {
0020 namespace concept_checking
0021 {
0022 template <void(*)()> struct instantiate {};
0023 }
0024
0025 template <class ModelFn> struct concept_check_;
0026
0027 template <class Model>
0028 void concept_check_failed()
0029 {
0030 ((Model*)0)->~Model();
0031 }
0032
0033 template <class Model>
0034 struct concept_check
0035 {
0036 concept_checking::instantiate<concept_check_failed<Model> > x;
0037 enum { instantiate = 1 };
0038 };
0039
0040 # ifdef BOOST_OLD_CONCEPT_SUPPORT
0041
0042 template <class Model>
0043 void constraint_check_failed()
0044 {
0045 ((Model*)0)->constraints();
0046 }
0047
0048 template <class Model>
0049 struct constraint_check
0050 {
0051 concept_checking::instantiate<constraint_check_failed<Model> > x;
0052 enum { instantiate = 1 };
0053 };
0054
0055 template <class Model>
0056 struct concept_check_<void(*)(Model)>
0057 : conditional<
0058 concept_checking::has_constraints<Model>::value
0059 , constraint_check<Model>
0060 , concept_check<Model>
0061 >::type
0062 {};
0063
0064 # else
0065
0066 template <class Model>
0067 struct concept_check_<void(*)(Model)>
0068 : concept_check<Model>
0069 {};
0070
0071 # endif
0072
0073
0074
0075
0076 # define BOOST_CONCEPT_ASSERT( ModelInParens ) \
0077 enum { BOOST_PP_CAT(boost_concept_check,__LINE__) = \
0078 ::boost::concept_check_<void(*) ModelInParens>::instantiate \
0079 }
0080 }
0081
0082 #endif