
14 Sep
2004
14 Sep
'04
11:38 p.m.
"Terje Slettebø" <tslettebo@broadpark.no> wrote #include <boost/operator_traits/has_plus_op.hpp> #include <boost/operator_traits/has_minus_op.hpp> #include <boost/concept_traits/std/is_assignable.hpp> template<class T1,class T2> struct is_my_concept : mpl::and_< is_assignable<T1>, is_assignable<T2>, has_plus_op<T1, T2>, has_minus_op<T1, T2>
{};
Why not : has_op< T1,plus, T2> ? hence: #include <boost/operator_traits/has_ops.hpp> template<class T1, class Opa, class Opb,class T2> struct is_my_concept : mpl::and_< is_assignable<T1>, is_assignable<T2>, has_op<T1, Opa,T2>, has_op<T1, Opb, T2>
{};
eg + - * / believe me this saves a lot of coding. regards Andy Little