DMD 1.019 and 2.003 releases
Jarrett Billingsley
kb3ctd2 at yahoo.com
Mon Jul 23 11:59:25 PDT 2007
"Walter Bright" <newshound1 at digitalmars.com> wrote in message
news:f82mav$2t9v$4 at digitalmars.com...
> Craig Black wrote:
>> Very nice Walter! Question about traits. I'm guessing allMembers
>> returns both functions and fields? Is there an isField or isFunction to
>> differentiate?
>
> You can look at the types to see if they are data or functions. But
> probably more traits need to be added - I thought I'd wait on that to see
> just what was required, rather than throw in a lot of useless geegaws.
> It's hard to predict in advance.
If you had
class A
{
void function() f;
void delegate() g;
void foo() {}
}
What would be f's type, g's type, and foo's type?
More information about the Digitalmars-d-announce
mailing list