Three related questions:
1) Is there a way to force a function to be always executed at
compile time (when it's possible to do so) no matter what context
it's called in?
2) Is it possible to specialize a function based on whether or
not the parameter that was passed in is a compile time constant?
3) Does any D compiler currently optimize out a conditional
branch which _can_ be evaluated at compile time (but which isn't
forced into CTFE)? Like:
int getValue(bool b)
{
return b ? 123 : 456;
}
//...
auto value = getValue(true);