Killing equals_t
bearophile
bearophileHUGS at lycos.com
Sun Dec 23 06:50:06 PST 2012
Jonathan M Davis:
> (since D1 made the mistake of having opEquals return int),
I think it wasn't a mistake, more like a design choice. In some
cases (especially when there is no inlining) computing and
returning an int is more efficient than converting to bool.
In practice I think the increase in performance is not
significant with modern compilers, and I prefer the clarity of a
bool result.
Bye,
bearophile
More information about the Digitalmars-d
mailing list