Related articles |
---|
Grammar problems gerhardt@schleissheimer.de (Michael Gerhardt) (2001-01-26) |
Re: Grammar problems smoleski@surakware.com (Sebastian Moleski \(SurakWare\)) (2001-01-28) |
Re: Grammar problems mahesha@india.hp.com (mahesha) (2001-02-01) |
From: | "Sebastian Moleski \(SurakWare\)" <smoleski@surakware.com> |
Newsgroups: | comp.compilers |
Date: | 28 Jan 2001 02:11:14 -0500 |
Organization: | T-Online |
References: | 01-01-158 |
Keywords: | parse |
Posted-Date: | 28 Jan 2001 02:11:14 EST |
"Michael Gerhardt" <gerhardt@schleissheimer.de>:
> I started generating a parser in a standard grammar with the compiler
> generator coco. I do not not know if anybody is used to this tool, but
> my main problem is in the grammar itself. I need to describe in which
> it is allowed that Identifiers (variable names, etc.) CAN be called
> like keywords. I do not know who made this specification, but this is
> a severe problem for me. I wrote the complete grammar and after runnig
> through a sample of code the error occured: Compilation error: keyword
> expected...
Just don't use parser/compiler generators. Write one yourself. If you
don't want to, I can send you the base package for our QP compiler
(written in C++). Since QP allows identifiers to be the same as
certain keywords, it would probably work with your base language.
sm
Return to the
comp.compilers page.
Search the
comp.compilers archives again.