]> git.saurik.com Git - bison.git/blobdiff - data/lalr1.java
NEWS: spell fixes.
[bison.git] / data / lalr1.java
index 43e9b9705c694fc7f5ef0c748c0b45b44f7f062c..a40d6c272a6ee2374acf437b9c6f83c1a4698825 100644 (file)
@@ -686,7 +686,7 @@ m4_popdef([b4_at_dollar])])dnl
               }
 
             /* Pop the current state because it cannot handle the error token.  */
-            if (yystack.height == 1)
+            if (yystack.height == 0)
               return false;
 
             ]b4_locations_if([yyerrloc = yystack.locationAt (0);])[
@@ -848,7 +848,7 @@ m4_popdef([b4_at_dollar])])dnl
     /* The symbols being reduced.  */
     for (int yyi = 0; yyi < yynrhs; yyi++)
       yy_symbol_print ("   $" + (yyi + 1) + " =",
-                       yystos_[yystack.stateAt(yyi + 1 - yynrhs)],
+                       yystos_[yystack.stateAt(yynrhs - (yyi + 1))],
                        ]b4_rhs_value(yynrhs, yyi + 1)b4_locations_if([,
                        b4_rhs_location(yynrhs, yyi + 1)])[);
   }