On 7/12/12 4:50 PM, Steven Schveighoffer wrote:
On Thu, 12 Jul 2012 16:27:39 -0400, Andrei Alexandrescu
<seewebsiteforem...@erdani.org> wrote:

On 7/12/12 4:20 PM, Steven Schveighoffer wrote:
I think this discussion is somewhat academic at this point, as Andrei
seems not too keen on the idea of having dual base classes.

Well I wasn't keen on eliminating the four methods and look what
happened!

My personal opinion is we should simply eliminate the four methods (or
at least the three required for AAs), fix AAs, and deal with the
fallout. I can't really remember the last time I simply used
obj1.opEquals(obj2) to do comparisons instead of obj1 == obj2 (which
should do the right thing if obj1.opEquals(obj2) is valid). The code
that relies on this is probably very rare. I certainly would *love* to
rewrite all my opCmp and opEquals functions to accept the minimal base
class instead of doing the dual dispatch dance with Object parameters.

I agree not a lot of people use obj1 == obj2 instead of obj1.opEquals(obj2), but I assume quite a few override opEquals and rely on it being called.

Andrei

Reply via email to