Summary: format() doesn't work with alias this
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos

--- Comment #0 from Andrej Mitrovic <> 2012-02-26 
18:23:19 PST ---
import std.stdio;
import std.string;

struct Wrap
    string a;
    alias a this;

struct Foo
    Wrap wrap;
    string toString() { return format("%s", wrap); }

void main()
    Foo foo;

std.format.FormatException@std\format.d(4400): Can't convert test.Wrap to
string: "string toString()" not defined

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to