On 4/15/15 4:34 PM, "=?UTF-8?B?Ik3DoXJjaW8=?= Martins\" <[email protected]>\"" wrote:
On Wednesday, 15 April 2015 at 19:16:55 UTC, Steven Schveighoffer wrote:

What about:

import std.format;
app.formattedWrite("foo%sbar", var);

Well, but wouldn't that incur the cost of parsing the format
string, for no benefit?

The benefit is, you are not limited to strings :P

But yeah, if it's just strings, you have not much benefit. However, I don't know what the cost is for parsing compared to the rest, it may not be too significant.

I like Ali's idea, make it a general purpose "putAll" primitive, goes right in std.range.primitives.

-Steve

Reply via email to