CTFE - compiling other languages inside D

Ary Manzana ary at esperanto.org.ar
Wed Aug 10 11:15:21 PDT 2011


On 8/10/11 2:09 PM, Marco Leise wrote:
> With the recent ORM and RegEx projects dissecting SQL statements and
> regular expressions turning them into D code, I am impressed by the
> possibilities of CTFE. Where are the limitations to this system? An
> unlikely example would be a C compiler within CTFE that takes a string
> of C source code and turns it into a D mixin. Is that possible?

I think it's possible, though CTFE can't access outside resources.

In my ideal language with CTFE capabilites, you say how to connect to 
the database and at compile-time the classes are generated from that.


More information about the Digitalmars-d mailing list