template mixins vs. string mixins
simen.kjaras at gmail.com
Sat Nov 6 02:47:02 PDT 2010
Trass3r <un at known.com> wrote:
> In the past template mixins were a neat special usecase of templates.
> Now with the "mixin template()" syntax they've become a separate thing
> because you can add special code for handling them, e.g. allowing them
> to add constructors to classes.
> The question is: what is their right to exist? Is there anything you can
> do with them you can't with string mixins (or vice versa)?
String mixins are, strictly speaking, more powerful than template mixins.
However, the syntax is unwieldy in comparison.
More information about the Digitalmars-d-learn