On Mon, 20 Apr 2015 21:00:34 +0000, extrawurst wrote:

> On Monday, 20 April 2015 at 20:36:06 UTC, ketmar wrote:
>> On Mon, 20 Apr 2015 20:31:36 +0000, extrawurst wrote:
>>
>>> static if(__ctfe){}
>>
>> small fix: simply `if (__ctfe)`, `static if (__ctfe)` is error.
>> ;-)
> 
> __ctfe is not readable at compile time ? thats unfortunate..

it will have no sense. DMD is able to eliminate dead code in this case, 
so `if (__ctfe)` will generate plain function. and there is no sense in 
do `static if` for functions, as functions is not instantiating, i.e. 
that will be processed only once, and you will be unable to use function 
both in CTFE and in run time.

Attachment: signature.asc
Description: PGP signature

Reply via email to