June 03, 2007 Re: PHP-style (embedded variables) print statements | ||||
|---|---|---|---|---|
| ||||
IMHO both implementations are really fine. As someone asked above - is it possible to avoid mixin(echo(...)) somehow, and have nice and clean echo("Blah $(var+1) blah") ? It would be totally awesome, I think.
| ||||
June 04, 2007 Re: PHP-style (embedded variables) print statements | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Dejan Lekic | Dejan Lekic wrote:
> IMHO both implementations are really fine. As someone asked above - is it possible to avoid mixin(echo(...)) somehow, and have nice and clean echo("Blah $(var+1) blah") ? It would be totally awesome, I think.
AFAIK, it's not possible to eliminate the mixin() yet. But, it will definitely be possible with macros. There's a lot of 'low-lying fruit' for macros -- even the tiniest bit of syntax sugar will make usage of this kind of code almost perfect.
The nice thing is, that we don't need to postulate about what will be possible with AST macros -- we can develop the code already. It's just got these messy 'mixin()'s all over it. <g>.
| |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply