[dmd-internals] [D-Programming-Language/dmd] 6ef6b7: Fixes Issue 5385 - Access must be checked for stat...

kenji hara k.hara.pg at gmail.com
Sun Dec 23 04:37:01 PST 2012


2012/12/23 Philippe Sigaud <philippe.sigaud at gmail.com>

>
> Thanks for the hint, this now works:
>>
>> bool listMembers(T)()
>> {
>>     static if (is(T P == super))
>>         static if(P.length > 0)
>>             listMembers!(P[0])();
>>
>>     alias typeof(T.tupleof) TTypes;
>>
>
> I don't get this. T is a type, right? So what does T.tupleof do? Shouldn't
> that be `typeof(T.init.tupleof)`?
>

T.tupleof generates a tuple of field *symbols*.
Getting type from a tuple of symbols returns a tuple of types in D.

Kenji Hara
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/dmd-internals/attachments/20121223/294d3efa/attachment.html>


More information about the dmd-internals mailing list