Re: Adding an interpreted language to program

"me262" <>
29 Mar 2007 23:07:14 -0400

          From comp.compilers

Related articles
Adding an interpreted language to program (me262) (2007-03-29)
Re: Adding an interpreted language to program (me262) (2007-03-29)
Re: Adding an interpreted language to program (Louis Krupp) (2007-03-30)
| List of all articles for this month |

From: "me262" <>
Newsgroups: comp.compilers
Date: 29 Mar 2007 23:07:14 -0400
Organization: Compilers Central
References: 07-03-105
Keywords: interpreter, comment
Posted-Date: 29 Mar 2007 23:07:14 EDT

On Mar 28, 10:01 pm, "me262" <> wrote:
> I am facing a task of hooking up my program to an intepreted
> language for front end. I know nothing about compiler theory. Is there
> a step-by-step guide on how to do that?
> I looked into some tools such and ANTLR and GOLD. Somehow, they
> would produce an AST. But how do I work it to do things that are
> useful, for example, printing "Hello world: we saw a = 10?".
> Thanks,
> [This question comes up a lot, and the best advice is NOT to try to
> write your own interpreter. There are plenty of interpreted languages
> already such as TCL, Lua, and Python, any of which can be used to
> drive your application. -John]

Hi John,

    Thanks for the comment. I totally agree with what you said. But in
our particular branch of engineering, there are thousands of scripts
already written in an old interpretive language. As a new comer, we
must be able to pop in CD, install and kick ass. We just can't ask
customers to Pythonize first.
[In that case, you'll have to reimplent your scripting language. Ugh.
I'd suggest parsing into an AST or RPN, then interpret that, rather
than trying to interpret directly from the parser. -John]

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.