At 15:10 -0700 2002/01/17, Scott Raney wrote: >That's my point: the required lookahead in the case of "number" is 3, >not 1.
All LR(n) grammars, n > 1, can be rewritten as LR(1) (to a grammar producing the same language) and even to LR(0) if each sentence is followed by an end marker, see Robin Hunter, "Compilers", sec. 5.2. And all grammars that can be parsed by a predictive parser can be parsed by LR(n) techniques, see Aho et al, "Compilers...", sec. 4.7. So assuming those conditions, you should have a language describable by a LR(1) grammar. Then the question is whether it can be cut down to LALR(1), which is what Bison uses. Hans Aberg * Email: Hans Aberg <mailto:[EMAIL PROTECTED]> * Home Page: <http://www.matematik.su.se/~haberg/> * AMS member listing: <http://www.ams.org/cml/> _______________________________________________ Freecard-general mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/freecard-general