quirks of functions and delegates

Jarrett Billingsley kb3ctd2 at yahoo.com
Tue Jul 31 18:39:47 PDT 2007


"BCS" <ao at pathlink.com> wrote in message 
news:ce0a3343c58c8c9a19db144d622 at news.digitalmars.com...
> might this work? (I haven't tried it yet)
>
> template T(F)
> {
>   staic if(is(F R == function))
>   else
>     static assert(false);
> }

shorter:

template T(F)
{
    static assert(is(F == function));
} 





More information about the Digitalmars-d mailing list