CT Busy Beaver

bearophile bearophileHUGS at lycos.com
Mon Aug 20 05:05:13 PDT 2012


Ali Çehreli:

> I thought that it was a bug that the compiler does not 
> construct an object and call opCall() on it.

In the D front-end there are some well known bugs regarding 
opCall (and I think there is a patch too).



> Works if the two 'static if' blocks are connected with an else:
>
>     static if (is (T : int)) {
>         enum Foo = [ T.init, T.init ];
>
>     } else static if (is (T : long)) {  // <-- else makes it 
> compile
>         enum Foo = [ T.init ];
>     }

I think the problem is different:
http://dpaste.dzfl.pl/86bcd51a

Bye,
bearophile


More information about the Digitalmars-d-learn mailing list