DIP 1027--String Interpolation--Final Review Discussion Thread

Paolo Invernizzi paolo.invernizzi at gmail.com
Wed Feb 5 11:38:58 UTC 2020


On Wednesday, 5 February 2020 at 11:24:46 UTC, Sebastiaan Koppe 
wrote:
> On Wednesday, 5 February 2020 at 10:46:11 UTC, Paolo Invernizzi 
> wrote:
>> String interpolation is not solving anything that needs to be 
>> solved
>
> Readability is a moving target, and a subjective one as well. A 
> lot programmers I have worked with find string interpolation to 
> reduce the ugly-ness of their code, and I completely agree with 
> them.
>
> To me that means it is a feature worth having.

I agree with you, I use string interpolation all the time, in 
python, or javascript for example

> On top of that string interpolation can be used for DSL work, 
> something D is well suited for, as well as for string mixins.

That's fine, I'm doing SQL parsing in D, so definitely that would 
help.

The all point is that, simply, IMHO, with that DIP in place, I 
would stick with business-as-usual, and go with the standard way 
of writing `bla %s foo %d`.format(bar, baz).

A different beast is Adam / Steven proposal ... but to this one, 
my vote will be -1.








More information about the Digitalmars-d mailing list