compile-time explicitness

Gor F. Gyolchanyan gor.f.gyolchanyan at gmail.com
Fri Sep 23 09:20:21 PDT 2011


About enum: it still stays. at least until D3 or so.
enum has it's own meaning too. the variable part is the least important part of
what i presented.

Not qite. __ctfe can solve many problems, but, for example, you can't use __ctfe
to determine whether you should use to!string or toStringNow.

__ctfe can't allow you to have both compile-time and run-time versions of the
function body simultaneously. DMD will still report an error, since __ctfe is a
run-time defined value and cannot be used in static if.

__ctfe can't help make non-functional-programming style templates.

__ctfe can't allow you to define temporary locals to store intermediate results of
computation with template parameters, which can then be used in a static if.


More information about the Digitalmars-d mailing list