On 9/28/2016 1:40 PM, Timon Gehr wrote:
What's wrong with that usage?

Because then something other than comparison is happening with <=, <, >, >= and there'll be nothing in the code to give the user a hint.


(This is NOT expression templates.)

Right, but it's an enabler of expression templates. Discussion of more powerful operator overloading cannot be divorced from expression templates, and once ETs are in we'll be stuck with them forever.


D has many very powerful modeling abilities, but so far we've tried to stay away from things that make context-free user understanding of code unduly difficult. It should not be necessary to use an IDE to understand code.

In that category are things like text macros, AST macros, user-defined syntax, non-arithmetic operator overloading, and expression templates.

Reply via email to