Re: Dangling else

SM Ryan <>
24 Feb 2006 09:37:27 -0500

          From comp.compilers

Related articles
Dangling else (borneq) (2006-02-19)
Re: Dangling else (2006-02-19)
Re: Dangling else (SM Ryan) (2006-02-24)
Re: Dangling else (Russ Cox) (2006-02-24)
Re: Dangling else (Russ Cox) (2006-02-24)
Re: Dangling else (SM Ryan) (2006-03-05)
Re: Dangling else (SM Ryan) (2006-03-05)
Re: Dangling else (=?ISO-8859-1?Q?Jan_Vorbr=FCggen?=) (2006-03-05)
Re: Dangling else (2006-03-05)
[16 later articles]
| List of all articles for this month |

From: SM Ryan <>
Newsgroups: comp.compilers
Date: 24 Feb 2006 09:37:27 -0500
Organization: Quick STOP Groceries
References: 06-02-136
Keywords: parse, syntax
Posted-Date: 24 Feb 2006 09:37:27 EST

# But - how resolve conflict depends on operator precedence and left/right
# association? In nice site:htm:
# we have:

I have a silly suggestion--avoid the whole problem. The dangling-else
syntax problem was solved over 40 years ago. But apparently the one
time exercise of adding the extra productions is too burdensome, so
we must instead use ever more complicated rules for parser generators.

The first language with CF grammar specified, Algol-60, managed to
to show how to parse expressions according to precedence and
associativity by simply writing the rules a particular way. But again
this is too burdensome; instead it is better to add all these
obscure %xyzzy directives to parser generators.

Oh, god, pride of man
broken in the dust again.

SM Ryan
A bunch of savages in this town.

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.