Related articles |
---|
REQ: Flex++Bison++ example of expressions. pwk@news.eb.ele.tue.nl (1996-02-09) |
From: | pwk@news.eb.ele.tue.nl (Pieter Kuppens) |
Newsgroups: | comp.compilers |
Date: | 9 Feb 1996 17:01:19 -0500 |
Organization: | Eindhoven University of Technology, Digital Information Systems Group |
Keywords: | yacc, lex, question |
Hello,
I'm making a compiler with Flex++ 2.3.8-7 and Bison++ 1.21-8, and I'm
stuck with some toy compiler examples.
Anyone used these tools for a grammar including for instance expressions?
expr: term | expr '+' term
term: fact | term '*' fact
fact: atom | '(' expr ')'
atom: INT | IDENT
I'm specially interested in the parse tree contruction as clear class
definition, with inheritance.
Regards,
Pieter Kuppens --- pwk@eb.ele.tue.nl
Eindhoven University of Technology --- EH 11.24 --- (+31)40-247 3394
E.S.V.V. Pusphaira on WWW; http://www2.stack.urc.tue.nl/Pusphaira/
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.