http://d.puremagic.com/issues/show_bug.cgi?id=5042



--- Comment #5 from bearophile_h...@eml.cc 2012-04-24 19:07:34 PDT ---
(In reply to comment #4)

> After all, you should use std.string.xformat instead of std.string.format in
> 2.060 and later.

Thank you Hara, this works:

import std.stdio: writeln, writefln;
import std.string: xformat;
struct Foo { int x; }
void main() {
    writeln(Foo(1)); // ==> Foo(1)
    writefln("%s", Foo(1)); // ==> Foo(1)
    writeln(xformat("%s", Foo(1))); // ==> Foo(1)
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to