>>> Right now we can get a bounding box for two processors easily
>>> enough, and (I am sure you are gonna love this...) overload '&&' to
>>> return true if they intersect.
>> 
>> If you must use operator overloading, at least use '&' instead?
>> Bitwise AND resembles an intersection operation more than logical AND
>> does.

Nah, 

bool intersect(const BoundaryDescription &other) const {}

will work just fine for me...  I kinda just wanted to stir things up (quiet
day in the office),

> How about neither?  Quoting from this thread:
> http://groups.google.com/group/comp.lang.c++.moderated/browse_frm/thread/653d5
> 49fc65b1129/cbd2edba6796b627?hl=en&lnk=gst&q=overload++%26%26#cbd2edba6796b627
> 
> Operators like ?:, but also &&, || and , (the comma operator)
> introduce sequence points and impose ordering, neither of which
> occurs in the case of overloading....
> 
> Operators like , (the comma operator), unary & and ?: (for the
> second and third parameters) are already defined for all
> possible types.  Overloading them changes the semantics of a
> previously legal program.  As such, they shouldn't be used, even
> when the can be legally used.

And apparently succeeded. ;-)

-Ben


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Libmesh-devel mailing list
Libmesh-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libmesh-devel

Reply via email to