mixin identifiers concept

Ola Fosheim Grøstad ola.fosheim.grostad at gmail.com
Wed Feb 2 13:13:13 UTC 2022


On Wednesday, 2 February 2022 at 12:24:32 UTC, Nick Treleaven 
wrote:
> String interpolation would be pretty much just as bad for 
> performance because it still requires the entire declaration to 
> be put in a string, rather than just an identifier. That whole 
> string needs to be formatted and turned into code, when we'd 
> rather be reading code in the first place!

If you have to use a *mixin* for an identifier on a regular basis 
then that suggests to me that something is wrong with the design 
of the application or that some other language feature is missing.

*mixin* should be viewed as an emergency escape hatch 
compenstating for language deficiencies, not as a solution.




More information about the Digitalmars-d mailing list