
18 Mar
2011
18 Mar
'11
6:11 a.m.
has_operator_xxx comes with a built in type qualifier abstraction, which means that it does never make sense to use type qualifiers with has_operator_xxx<...>::value meta expressions?
it still does. Another example: T operator+(T&); has_operator_unary_plus<const T&>::value is false. This also is false: has_operator_plus_equal<const int, int>::value So you should use the types you want to pass to the operator, with cv and reference/pointer qualifiers. Frédéric