in a template argument, specify which object member to access?
Mengu via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Feb 8 14:38:45 PST 2016
On Monday, 8 February 2016 at 21:09:47 UTC, cy wrote:
> object.member lets me access the member of the object, but what
> if I want to access those members in a generic way, but in a
> different arrangement depending on context? Like if I wanted to
> first follow a tree down, and second priority would be going
> left to right, but then I wanted to first go right, and second
> priority would be going down to up.
>
> [...]
i believe you can use __traits(getMember) there.
More information about the Digitalmars-d-learn
mailing list