On Monday, 21 May 2018 at 14:48:23 UTC, Mike Parker wrote:
Nick Sabaluasky's first post to the D Blog is a tip on how to create an aliased type that keeps its name in error messages.

Nice. Interestingly, the error message references the wrong type when trying to access static members:

struct MT {
    int _payload;
    alias _payload this;
}

unittest {
    MT a;
    a.foo = 3;  // Error: no property foo for type MT
    MT.foo = 3; // Error: no property foo for type int
}

https://issues.dlang.org/show_bug.cgi?id=18892

--
  Simen

Reply via email to