
11 Mar
2004
11 Mar
'04
11:09 p.m.
Douglas Gregor wrote: [...]
The "contains" member is there precisely because I knew about the cases where we want to check containment but don't want to use operator==.
I must be missing something. The "contains" member is there? Where? I don't see "contains" in the source, in the docs, and my compiler doesn't see it, either (it has much better vision).
I guess the above will either convince you that:
1) operator== is sufficiently limited so that it is safe to use, because bad uses end up with compiler errors. 2) operator== is still a terrible way to represent check the containment relationship, and turns into a bloody mess of requirements.
I don't view these two options as mutually exclusive. ;-)