
Frédéric Bron wrote:
Good news for the return type of operators: I have been able to check for exact void return and have default "dont_care":
template< class LHS, class RHS=LHS, class RET=dont_care > has_operator_plus;
1. operator+(A, A) exists and returns void
has_operator_plus<A, A>::value -> true (dont check return type) has_operator_plus<A, A, void>::value -> true (check for exact void return type) has_operator_plus<A, A, R>::value -> false (void!=R)
2. operator+(A, A) exists and returns R!=void
has_operator_plus<A, A>::value -> true (dont check return type) has_operator_plus<A, A, void>::value -> false (void!=R) has_operator_plus<A, A, R>::value -> true (void!=R)
3. operaot+(A, A) does not exist
has_operator_plus<A, A>::value -> false has_operator_plus<A, A, void>::value -> false has_operator_plus<A, A, R>::value -> false
I think this is now much better.
Could you make the same analysis with "const, volatile and references", as parameter and return type? Thanks, Vicente -- View this message in context: http://boost.2283326.n4.nabble.com/Review-Boost-Type-Traits-Extension-by-Fre... Sent from the Boost - Dev mailing list archive at Nabble.com.