automatic detection and replacement of constructs causing shift/reduce conflicts

Tom Kramer <kramer@cme.nist.gov>
Sat, 29 Mar 2008 08:43:22 -0400

          From comp.compilers

Related articles
automatic detection and replacement of constructs causing shift/reduce kramer@cme.nist.gov (Tom Kramer) (2008-03-29)
| List of all articles for this month |
From: Tom Kramer <kramer@cme.nist.gov>
Newsgroups: comp.compilers
Date: Sat, 29 Mar 2008 08:43:22 -0400
Organization: Compilers Central
Keywords: parse, LALR, question
Posted-Date: 29 Mar 2008 13:46:48 EDT

I built a system that reads a file written in ISO standard EBNF and
builds a parse tree. Then it generates BNF equivalent to the EBNF and
writes YACC. While it is generating BNF, it examines the EBNF to see
if there are any of six types of construct that are known to cause
shift/reduce conflicts. Alternate BNF constructs that do not change
the language and do not cause a shift/reduce conflict are known for
all six types. The system uses the alternate constructs while writing
the YACC. The work was done for a real-world application in which
there were 22 instances of the six sinful construct types.


There is nothing new about EBNF-to-YACC conversion, but I have not
been able to find anything in print about the automatic detection
and replacement of constructs that cause shift/reduce conflicts.
I am writing a paper about this.


1. Does anyone know of any prior work in this area?


2. Does this sound like a paper that will be of interest to
journals, and if so, what journals?


Thanks for your help.


Tom Kramer
kramer@cme.nist.gov


Post a followup to this message

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