
14 Mar
2007
14 Mar
'07
7:05 p.m.
Frank Mori Hess wrote:
I have to say I really am not a big fan of needless overloading of the languages operators like logical || and &&. Especially when you are overloading them with functions that really don't correspond to the original operators. What if I want to overload || with a function that actually does correspond to logical or, like
Future<bool> operator||(const Future<T> &a, const Future<U> &b);
1. Why do you would do that? Do you have a use case? 2. If you really have to do that, simply do not include the header(s) defining the operators. Regards Hartmut