D operator overloading. Why that way?

Hauleth lukasz at niemier.pl
Wed Sep 19 07:40:15 PDT 2012


Is there any reason to allow overload `op=`? IMHO it should be 
left illegal and should be interpreted always as `a = a op b`. It 
will be simpler and less confusing.

Also why `opEquals` is independent from `opCmp`? Once again 
`opEquals` should be removed and equality will be provided by 
`opCmp() == 0`.


More information about the Digitalmars-d mailing list