]> git.saurik.com Git - bison.git/commitdiff
* data/glr.c (yyresolveValue): Add default case to pacify
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 15 Sep 2005 14:16:54 +0000 (14:16 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 15 Sep 2005 14:16:54 +0000 (14:16 +0000)
gcc -Wswitch-default.  Problem reported by twlevo@xs4all.nl.

ChangeLog
data/glr.c

index 76152369c8d99ed5a36181f1dd1fb5f647f5ff65..d7b4ff85a18258f7279dc3f20ce4e5ad97751276 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
 
+       * data/glr.c (yyresolveValue): Add default case to pacify
+       gcc -Wswitch-default.  Problem reported by twlevo@xs4all.nl.
+
        * NEWS: Document when yyparse started to return 2.
        * doc/bison.texinfo (Parser Function): Document when yyparse
        returns 2.
index d2f192187e99feeab36a1547f5f93f7089be52ba..5bb8e2d06b516b7b03fe5f679872a30796f3f7d8 100644 (file)
@@ -1674,6 +1674,11 @@ yyresolveValue (yySemanticOption* yyoptionList, yyGLRStack* yystack,
              yybest = yyp;
              yymerge = yyfalse;
              break;
+           default:
+             /* This cannot happen so it is not worth a YYASSERT (false),
+                but some compilers complain if the default case is
+                omitted.  */
+             break;
            }
          yypp = &yyp->yynext;
        }