Discussion Thread: DIP 1036--String Interpolation Tuple Literals--Community Review Round 2
Steven Schveighoffer
schveiguy at gmail.com
Fri Jan 29 19:35:28 UTC 2021
On 1/29/21 1:49 PM, Paul Backus wrote:
> When you find yourself saying things like "it's fine, we can just add
> special
> cases to printf...and tuple...and mixin...", that's a sure sign that
> something
> has gone wrong in your language-feature design.
This seems to suggest we aren't done when the DIP is passed. That isn't
the case.
No special cases are needed. mixins will work, printf will not (unless
you want to write a wrapper). tuple doesn't need a special case, it will
do what you ask, you have to ask it the write thing.
These forums are full of "how do I do X with D?" and someone answers and
they say "Thanks" and move on, having learned something. It is no
different here. People have asked "You can't use printf with it", and I
answered the question. I'm not saying "hey, let's add a printf wrapper
to phobos and only then this DIP will be complete", I'm saying "if for
some reason you want to use it with printf, here's how you would do it".
It seems we are in a trap where someone says "yeah but you can't do
this", and answering that question "no, you're right" means it's a
failed feature. Answering that question with "yes, here's how" ALSO
means it's a failed feature.
-Steve
More information about the Digitalmars-d
mailing list