From cc09e5beb929422f619906f05daa777ffaf5ade7 Mon Sep 17 00:00:00 2001 From: "Joel E. Denny" Date: Sun, 6 Mar 2011 12:54:35 -0500 Subject: doc: clean up terminology for mysterious conflicts. * doc/bison.texinfo (Mystery Conflicts): Rename node to... (Mysterious Conflicts): ... this, which is already the section title and the name used in the index. Update all cross-references to this node. Also, don't imply that R/R conflicts are the only kind of mysterious conflict. (cherry picked from commit 5da0355aff4de57e96aba7b788c376fc779d83b1) --- ChangeLog | 9 +++++++++ doc/bison.texinfo | 24 ++++++++++++------------ 2 files changed, 21 insertions(+), 12 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0da88d5a..e1bfcc66 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2011-03-06 Joel E. Denny + + doc: clean up terminology for mysterious conflicts. + * doc/bison.texinfo (Mystery Conflicts): Rename node to... + (Mysterious Conflicts): ... this, which is already the section + title and the name used in the index. Update all cross-references + to this node. Also, don't imply that R/R conflicts are the only + kind of mysterious conflict. + 2011-03-06 Joel E. Denny lr.default-reductions: rename "all" value to "full". diff --git a/doc/bison.texinfo b/doc/bison.texinfo index 6408e2d1..a965753a 100644 --- a/doc/bison.texinfo +++ b/doc/bison.texinfo @@ -265,7 +265,7 @@ The Bison Parser Algorithm * Contextual Precedence:: When an operator's precedence depends on context. * Parser States:: The parser is a finite-state-machine with stack. * Reduce/Reduce:: When two rules are applicable in the same situation. -* Mystery Conflicts:: Reduce/reduce conflicts that look unjustified. +* Mysterious Conflicts:: Conflicts that look unjustified. * Tuning LR:: How to tune fundamental aspects of LR-based parsing. * Generalized LR Parsing:: Parsing arbitrary context-free grammars. * Memory Management:: What happens when memory is exhausted. How to avoid it. @@ -490,10 +490,10 @@ are called LR(1) grammars. In brief, in these grammars, it must be possible to tell how to parse any portion of an input string with just a single token of lookahead. For historical reasons, Bison by default is limited by the additional restrictions of LALR(1), which is hard to explain simply. -@xref{Mystery Conflicts, ,Mysterious Reduce/Reduce Conflicts}, for more -information on this. As an experimental feature, you can escape these -additional restrictions by requesting IELR(1) or canonical LR(1) parser -tables. @xref{LR Table Construction}, to learn how. +@xref{Mysterious Conflicts}, for more information on this. As an +experimental feature, you can escape these additional restrictions by +requesting IELR(1) or canonical LR(1) parser tables. @xref{LR Table +Construction}, to learn how. @cindex GLR parsing @cindex generalized LR (GLR) parsing @@ -6516,7 +6516,7 @@ This kind of parser is known in the literature as a bottom-up parser. * Contextual Precedence:: When an operator's precedence depends on context. * Parser States:: The parser is a finite-state-machine with stack. * Reduce/Reduce:: When two rules are applicable in the same situation. -* Mystery Conflicts:: Reduce/reduce conflicts that look unjustified. +* Mysterious Conflicts:: Conflicts that look unjustified. * Tuning LR:: How to tune fundamental aspects of LR-based parsing. * Generalized LR Parsing:: Parsing arbitrary context-free grammars. * Memory Management:: What happens when memory is exhausted. How to avoid it. @@ -7085,8 +7085,8 @@ redirects:redirect ; @end example -@node Mystery Conflicts -@section Mysterious Reduce/Reduce Conflicts +@node Mysterious Conflicts +@section Mysterious Conflicts @cindex Mysterious Conflicts Sometimes reduce/reduce conflicts can occur that don't look warranted. @@ -7242,7 +7242,7 @@ user feedback will help to stabilize them. For historical reasons, Bison constructs LALR(1) parser tables by default. However, LALR does not possess the full language-recognition power of LR. As a result, the behavior of parsers employing LALR parser tables is often -mysterious. We presented a simple example of this effect in @ref{Mystery +mysterious. We presented a simple example of this effect in @ref{Mysterious Conflicts}. As we also demonstrated in that example, the traditional approach to @@ -7277,7 +7277,7 @@ grammar file: %define lr.type ielr @end example -@noindent For the example in @ref{Mystery Conflicts}, the mysterious +@noindent For the example in @ref{Mysterious Conflicts}, the mysterious conflict is then eliminated, so there is no need to invest time in comprehending the conflict or restructuring the grammar to fix it. If, during future development, the grammar evolves such that all mysterious @@ -7622,7 +7622,7 @@ sequence of reductions cannot have deterministic parsers in this sense. The same is true of languages that require more than one symbol of lookahead, since the parser lacks the information necessary to make a decision at the point it must be made in a shift-reduce parser. -Finally, as previously mentioned (@pxref{Mystery Conflicts}), +Finally, as previously mentioned (@pxref{Mysterious Conflicts}), there are languages where Bison's default choice of how to summarize the input seen so far loses necessary information. @@ -11619,7 +11619,7 @@ Tokens}. @item LALR(1) The class of context-free grammars that Bison (like most other parser generators) can handle by default; a subset of LR(1). -@xref{Mystery Conflicts, ,Mysterious Reduce/Reduce Conflicts}. +@xref{Mysterious Conflicts}. @item LR(1) The class of context-free grammars in which at most one token of -- cgit v1.2.1