Am I evil for this?

Walter Bright newshound2 at digitalmars.com
Fri Oct 14 22:43:05 UTC 2022


On 10/14/2022 1:49 PM, Max H wrote:
> Potentially controversial response: Who cares? The alternative in D is basically 
> just the same code with some quotes around it (a DSL like pegged).

With color syntax highlighting, nobody will think the quoted string is ordinary 
D code. It's also why the `mixin` keyword is a keyword - to make it stand out.

> You can do real sin with operating overloading, or just badly chosen operators, 
> but this particular one really isn't that bad. The alternative is preprocessor 
> macros, which are considerably worse.

The best alternative to a proper DSL is to simply use functions instead of 
operators.



More information about the Digitalmars-d mailing list