|Code generation / markup language processing email@example.com (Scott Bissett) (1999-01-11)|
|Re: Code generation / markup language processing firstname.lastname@example.org (Norman Ramsey) (1999-01-15)|
|Re: Code generation / markup language processing Martin.Ward@SMLtd.Com (1999-01-20)|
|From:||Norman Ramsey <email@example.com>|
|Date:||15 Jan 1999 01:11:33 -0500|
|Organization:||University of Virginia Computer Science|
Scott Bissett <firstname.lastname@example.org> wrote:
>I am using a
>tool at work that was developed in-house to generate C-code...
>the only problem is, the architecture of
>the generated C-code is *compiled into the tool*!!!
>So, my quest is to build a better code generation tool...
I had reasonable success with a very simple macro-oriented approach.
M4 wasn't quite what I wanted, so I whipped up a preprocessor in Icon
(http://www.cs.arizona.edu/icon) to do the job. This worked fine
until the day we decided we didn't want just to emit C, we also wanted
to be able to emit Modula-3, or Java, or ML, or ... From that point
forward, code has gotten very klunky. The main problem seems to be
finding a reasonable internal representation of `program' that can be
mapped to any one of a number of programming languages. It's hard for
us to decide what features we want to exploit: objects? mutable state?
closures? memory management?
I'd love to hear from others who are successfully using multiple
high-level languages as target languages for a compiler or stub
Return to the
Search the comp.compilers archives again.