Related articles |
---|
Help wanted - getting started writing an interpretter dont@send.me.spam (SynapZ) (2001-09-21) |
Re: Help wanted - getting started writing an interpretter monnier+comp.compilers/news/@RUM.cs.yale.edu (Stefan Monnier) (2001-09-25) |
Re: Help wanted - getting started writing an interpretter joachim_d@gmx.de (Joachim Durchholz) (2001-09-25) |
Re: Help wanted - getting started writing an interpretter anton@mips.complang.tuwien.ac.at (2001-09-26) |
From: | SynapZ <dont@send.me.spam> |
Newsgroups: | comp.compilers |
Date: | 21 Sep 2001 23:45:14 -0400 |
Organization: | SynapZ |
Keywords: | interpreter, design |
Posted-Date: | 21 Sep 2001 23:45:14 EDT |
Hi all,
I'm writing a simple script language for a game I'm making and I've
been reading up on the area (never written a compiler before!). I've
decided to create a compiler with lex/yacc that produces a condense
bytecode output, to be interpretted by the game. Does this sound like
a sensible approach (small footprint target so need to keep compiled
scripts as small as possible) ?
I'm fairly confident that I can make the compiler with the help of lex
and yacc but the interpretter seems to be a completely separate issue.
Are there any tools out there to help automate this process (i.e.
generate an interpretter for a lex/yacc'd language)?
Can anyone point me towards some online resources that will get me
started writing an interpretter? The language is fairly simple - no
support for creation of variables, only simple IF..THEN..ELSE
branching and probably no looping. However, it does need to correctly
handle branching and evaluation of expressions.
Any info that will help get me started on this is much appreciated.
-Sy/\/apZ-
[Our usual advice is "don't do that". First look at existing scripting
languages like TCL, Python, Lua, and REXX and see if they won't do the
trick. -John]
Return to the
comp.compilers page.
Search the
comp.compilers archives again.