Compile Time D Expression Parser?
pjmlp at progtools.org
Sat Feb 25 23:53:58 PST 2012
Am 26.02.2012 03:25, schrieb d coder:
> I need to parse simple D expressions at compile time. I was wondering if
> somebody on the list has some example code that could be of help to me.
> I am working on an opensource constraint solver and expressions that I
> need to parse can be reasonably complex such as "x + y*n < 32 && x > 4".
> I want to code a string mixin that parses such expressions and writes
> out code that creates a parse tree for the given expression.
> Thanks and Regards
> - Puneet
How different is what you want to do from CTFE?
More information about the Digitalmars-d