Is it possible to force CTFE?

Don Clugston dac at nospam.com
Mon Oct 1 02:21:20 PDT 2012


On 27/09/12 15:01, bearophile wrote:
> Tommi:
>
>> 2) Is it possible to specialize a function based on whether or not the
>> parameter that was passed in is a compile time constant?
>
> I am interested in this since some years. I think it's useful, but I
> don't know if it can be implemented. I don't remember people discussing
> about this much.
>
> Bye,
> bearophile

It has been discussed very often, especially around the time that CTFE 
was first introduced. We never came up with a solution.



More information about the Digitalmars-d-learn mailing list