This is the mail archive of the
archer@sourceware.org
mailing list for the Archer project.
Re: Parser rewritting
- From: Tom Tromey <tromey at redhat dot com>
- To: Sergio Durigan Junior <sergiodj at redhat dot com>
- Cc: Project Archer <archer at sourceware dot org>
- Date: Tue, 30 Mar 2010 15:18:06 -0600
- Subject: Re: Parser rewritting
- References: <201003301546.34866.sergiodj@redhat.com>
- Reply-to: Tom Tromey <tromey at redhat dot com>
>>>>> "Sergio" == Sergio Durigan Junior <sergiodj@redhat.com> writes:
Sergio> The current parser is written using Bison, and unfortunately it
Sergio> is insufficient to satisfy our current needs, especially for C++
Sergio> productions.
A few particulars...
We ran into some problems with the function-like cast notation. I think
those are probably fixable, by not differentiating different kinds of
names here, but we think there will be more problems. E.g., I suspect
we'll run into problems when we get rid of the template name hack in the
lexer.
Also, there is no good way in bison to disable a production only when
the parsing language is C++. You can play games by returning different
tokens in different modes, or you can run a preprocessor on the grammar,
but both of those are pretty ugly.
Tom