templating opEquals/opCmp (e.g. for DSL/expression templates)
jmh530
john.michael.hall at gmail.com
Wed Feb 13 12:17:42 UTC 2019
On Wednesday, 13 February 2019 at 02:49:21 UTC, Nicholas Wilson
wrote:
> [snip]
>
> Imperfection should be a reason for adding things to make it
> better. That they can be abused and nobody does because that
> would be a stupid thing to do is of no relevance and certainly
> not a reason to not do it.
This kind of gets in to the opt-in vs. opt-out argument. If there
were a attribute that was something like
@enable("extended-operator-overloading") that would allow more
operators to be overloaded only within those blocks, then it
allows the default to be something restricted but gives users the
option to make something different if needed.
More information about the Digitalmars-d
mailing list