Related articles |
---|
Several parsing questions kidlim@yahoo.com (Agnes) (2002-03-09) |
Re: Several parsing questions jayanty4@yahoo.com (2002-03-11) |
Re: Several parsing questions joachim_d@gmx.de (Joachim Durchholz) (2002-03-17) |
Re: Several parsing questions joachim_d@gmx.de (Joachim Durchholz) (2002-03-17) |
From: | Joachim Durchholz <joachim_d@gmx.de> |
Newsgroups: | comp.compilers |
Date: | 17 Mar 2002 22:40:25 -0500 |
Organization: | Compilers Central |
References: | 02-03-034 02-03-056 |
Keywords: | parse |
Posted-Date: | 17 Mar 2002 22:40:25 EST |
jscid wrote:
>
> As of your 1st question there are several reasons that make a grammar
> ambigous one of them is left recursion. A production system is said to
> be left recursive if a nonterminal can be expanded into a string that
> begins with the same nonterminal. Due to this all the time the same
> nonterminal gets replaced and there is no end to this.
Sorry, this is wrong. A left-recursive grammar can be unambiguous (in
fact many LALR grammars are left-recursive). What you mean is that an LL
parser will get into an infinite loop if the grammar is left-recursive,
but that's different from grammar ambiguity.
Regards,
Joachim
Return to the
comp.compilers page.
Search the
comp.compilers archives again.