Library Typedefs are fundamentally broken
Daniel Murphy via Digitalmars-d
digitalmars-d at puremagic.com
Mon Sep 22 11:56:06 PDT 2014
"Vladimir Panteleev" wrote in message
news:oadjpzibjneyfutoydct at forum.dlang.org...
> What if you *want* a Typedef instantiation to be the same for all
> instantiations of a parent template?
Declare it outside the template and provide an alias inside. Like you would
with any other declaration you wanted common to all instantiations.
> I think you can have both if Typedef simply takes an "ARGS...", which
> defaults to TypeTuple!(__FILE__, __LINE__, __COLUMN__), but in this case
> can be overridden to TypeTuple!(Foo, T).
Yeah. If it wasn't for the syntax overhead, the ideal args is something
like this:
struct MyTypedef_Tag;
alias MyTypedef = Typedef!(basetype, init, MyTypedef_Tag);
More information about the Digitalmars-d
mailing list