<p dir="ltr"><br>
On 09 May 2016 19:01, "Stefan Koch via Digitalmars-d-announce" <<a href="mailto:digitalmars-d-announce@puremagic.com">digitalmars-d-announce@puremagic.com</a>> wrote:<br>
><br>
> Hi Guys,<br>
><br>
> I have been looking into the DMD now to see what I can do about CTFE.<br>
> Unfortunately It is a pretty big mess to untangle.<br>
> Code responsible for CTFE is in at least 3 files.<br>
> [dinterpret.d, ctfeexpr.d, constfold.d]<br>
> I was shocked to discover that the PowExpression actually depends on phobos! (depending on the exact codePath it may or may not compile...)<br>
> which let to me prematurely stating that it worked at ctfe [<a href="http://forum.dlang.org/thread/ukcoibejffinknrbzktv@forum.dlang.org">http://forum.dlang.org/thread/ukcoibejffinknrbzktv@forum.dlang.org</a>]<br>
><br>
> My Plan is as follows.<br>
><br>
> Add a new file for my ctfe-interpreter and update it gradually to take more and more of the cases the code in the files mentioned above was used for.<br>
><br>
> Do Dataflow analysis on the code that is to be ctfe'd so we can tell beforehand if we need to store state in the ctfe stack or not.<br>
><br>
> Or baring proper data-flow analysis: RefCouting the variables on the ctfe-stack could also be a solution.<br>
><br>
> I will post more details as soon as I dive deeper into the code.<br>
><br>
></p>
<p dir="ltr">Will be awesome. Particularly if you document the workings of ctfe, might make a great set of articles for a blog. </p>