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

--- Comment #9 from Andrej Mitrovic <[email protected]> ---
Would this getter give ref access? If so, we might as well make the
`Typedef_payload` field public. Otherwise we could make a UFCS function that
would avoid symbol conflicts:

-----
V getValue(T)(T t)
    /* if (isTypedef!T) */
{
    return t.Typedef_payload;
}
-----

This would be usable via:

Typedef!Type x;
x.getValue();  // assuming 'Type' doesn't define getValue
getValue(x);   // workaround if 'Type' *does* define getValue

Let me know what you think.

--

Reply via email to