bison-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

"parse error" -> "syntax error", and similarly for overflow message


From: Paul Eggert
Subject: "parse error" -> "syntax error", and similarly for overflow message
Date: Fri, 15 Nov 2002 13:00:07 -0800

I installed the following patch to fix Bison to conform to POSIX
(in one case) and to its documentation (in the other).

2002-11-15  Paul Eggert  <address@hidden>

        * data/glr.c, data/lalr1.cc, data/yacc.cc, doc/bison.texinfo,
        src/conflicts.c, src/parse-gram.y, src/tables.c, src/tables.h,
        tests/action.at, tests/calc.at, tests/conflicts.at,
        tests/cxx-type.at, tests/regression.at:
        "parse error" -> "syntax error" for POSIX compatibility.
        "parsing stack overflow..." -> "parser stack overflow" so
        that code matches Bison documentation.

--- NEWS.~1.77.~        2002-11-14 14:28:42.000000000 -0800
+++ NEWS        2002-11-15 12:28:12.000000000 -0800
@@ -2,6 +2,15 @@ Bison News
 ----------
 Changes in version 1.75c:
 
+* "parse error" -> "syntax error"
+  Bison now uniformly uses the term "syntax error"; formerly, the code
+  and manual sometimes used the term "parse error" instead.  POSIX
+  requires "syntax error" in diagnostics, and it was thought better to
+  be consistent.
+
+* "parsing stack overflow..." -> "parser stack overflow"
+  GLR parsers now report "parser stack overflow" as per the Bison manual.
+
 * GLR and inline
   Users of Bison have to decide how they handle the portability of the
   C keyword `inline'.
Index: data/glr.c
===================================================================
RCS file: /cvsroot/bison/bison/data/glr.c,v
retrieving revision 1.37
diff -p -u -r1.37 glr.c
--- data/glr.c  14 Nov 2002 23:18:55 -0000      1.37
+++ data/glr.c  15 Nov 2002 20:24:02 -0000
@@ -360,7 +360,7 @@ static const ]b4_int_type_for([b4_pgoto]
 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
    positive, shift that token.  If negative, reduce the rule which
    number is the opposite.  If zero, do what YYDEFACT says.
-   If YYTABLE_NINF, parse error.  */
+   If YYTABLE_NINF, syntax error.  */
 #define YYTABLE_NINF ]b4_table_ninf[
 static const ]b4_int_type_for([b4_table])[ yytable[] =
 {
@@ -866,8 +866,7 @@ yyexpandGLRStack (yyGLRStack* yystack]b4
   size_t yyn;
   yysize = yystack->yynextFree - yystack->yyitems;
   if (YYMAXDEPTH <= yysize)
-    yyFail (yystack][]b4_pure_args[,
-           "parsing stack overflow (%d items)", yysize);
+    yyFail (yystack][]b4_pure_args[, "parser stack overflow");
   yynewSize = 2*yysize;
   if (YYMAXDEPTH < yynewSize)
     yynewSize = YYMAXDEPTH;
@@ -914,8 +913,7 @@ yyexpandGLRStack (yyGLRStack* yystack]b4
 
 #else
 
-  yyFail (yystack][]b4_lpure_args[,
-          "parsing stack overflow (%d items)", yysize);
+  yyFail (yystack][]b4_lpure_args[, "parser stack overflow");
 #endif
 }
 
@@ -1596,7 +1594,7 @@ yyreportParseError (yyGLRStack* yystack,
          yycount = 0;
          /* Start YYX at -YYN if negative to avoid negative indexes in
             YYCHECK.  */
-         yysize = sizeof ("parse error, unexpected ")
+         yysize = sizeof ("syntax error, unexpected ")
            + strlen (yytokenName (*yytokenp));
          yyprefix = ", expecting ";
          for (yyx = yyn < 0 ? -yyn : 0; yyx < yytname_size && yycount <= 5;
@@ -1605,7 +1603,8 @@ yyreportParseError (yyGLRStack* yystack,
              yysize += strlen (yytokenName (yyx)) + strlen (yyprefix),
                yycount += 1, yyprefix = " or ";
          yymsg = yyp = (char*) malloc (yysize);
-         sprintf (yyp, "parse error, unexpected %s", yytokenName (*yytokenp));
+         sprintf (yyp, "syntax error, unexpected %s",
+                  yytokenName (*yytokenp));
          yyp += strlen (yyp);
          if (yycount < 5)
            {
@@ -1623,7 +1622,7 @@ yyreportParseError (yyGLRStack* yystack,
        }
       else
 #endif
-       yyerror (]b4_lyyerror_args["parse error");
+       yyerror (]b4_lyyerror_args["syntax error");
       yynerrs += 1;
     }
 }
@@ -1855,7 +1854,7 @@ yyrecoverParseError (yyGLRStack* yystack
            {
              yyundeleteLastStack (&yystack);
              if (yystack.yytops.yysize == 0)
-               yyFail (&yystack][]b4_lpure_args[, "parse error");
+               yyFail (&yystack][]b4_lpure_args[, "syntax error");
              YYCHK1 (yyresolveStack (&yystack]b4_user_args[));
              YYDPRINTF ((stderr, "Returning to deterministic operation.\n"));
              yyreportParseError (&yystack, yylvalp, yyllocp]b4_user_args[);
Index: data/lalr1.cc
===================================================================
RCS file: /cvsroot/bison/bison/data/lalr1.cc,v
retrieving revision 1.14
diff -p -u -r1.14 lalr1.cc
--- data/lalr1.cc       12 Nov 2002 07:21:01 -0000      1.14
+++ data/lalr1.cc       15 Nov 2002 20:24:02 -0000
@@ -484,7 +484,7 @@ b4_syncline(address@hidden@], address@hidden@])
       n_ = pact_[[state_]];
       if (pact_ninf_ < n_ && n_ < last_)
        {
-         message = "parse error, unexpected ";
+         message = "syntax error, unexpected ";
          message += name_[[ilooka_]];
          {
            int count = 0;
@@ -505,7 +505,7 @@ b4_syncline(address@hidden@], address@hidden@])
        }
       else
 #endif
-       message = "parse error";
+       message = "syntax error";
       error_ ();
     }
   goto yyerrlab1;
Index: data/yacc.c
===================================================================
RCS file: /cvsroot/bison/bison/data/yacc.c,v
retrieving revision 1.34
diff -p -u -r1.34 yacc.c
--- data/yacc.c 13 Nov 2002 09:49:49 -0000      1.34
+++ data/yacc.c 15 Nov 2002 20:24:02 -0000
@@ -425,7 +425,7 @@ static const b4_int_type_for([b4_pgoto])
 /* YYTABLE[[YYPACT[STATE-NUM]]].  What to do in state STATE-NUM.  If
    positive, shift that token.  If negative, reduce the rule which
    number is the opposite.  If zero, do what YYDEFACT says.
-   If YYTABLE_NINF, parse error.  */
+   If YYTABLE_NINF, syntax error.  */
 #define YYTABLE_NINF b4_table_ninf
 static const b4_int_type_for([b4_table]) yytable[[]] =
 {
@@ -662,7 +662,7 @@ int yychar;
 /* The semantic value of the lookahead symbol.  */
 YYSTYPE yylval;
 
-/* Number of parse errors so far.  */
+/* Number of syntax errors so far.  */
 int yynerrs;b4_location_if([
 /* Location data for the lookahead symbol.  */
 YYLTYPE yylloc;])
@@ -1017,12 +1017,12 @@ yyerrlab:
               yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++)
            if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
              yysize += yystrlen (yytname[yyx]) + 15, yycount++;
-         yysize += yystrlen ("parse error, unexpected ") + 1;
+         yysize += yystrlen ("syntax error, unexpected ") + 1;
          yysize += yystrlen (yytname[yytype]);
          yymsg = (char *) YYSTACK_ALLOC (yysize);
          if (yymsg != 0)
            {
-             char *yyp = yystpcpy (yymsg, "parse error, unexpected ");
+             char *yyp = yystpcpy (yymsg, "syntax error, unexpected ");
              yyp = yystpcpy (yyp, yytname[yytype]);
 
              if (yycount < 5)
@@ -1043,11 +1043,11 @@ yyerrlab:
              YYSTACK_FREE (yymsg);
            }
          else
-           yyerror (]b4_yyerror_args["parse error; also virtual memory 
exhausted");
+           yyerror (]b4_yyerror_args["syntax error; also virtual memory 
exhausted");
        }
       else
 #endif /* YYERROR_VERBOSE */
-       yyerror (]b4_yyerror_args["parse error");
+       yyerror (]b4_yyerror_args["syntax error");
     }
   goto yyerrlab1;
 
Index: doc/bison.texinfo
===================================================================
RCS file: /cvsroot/bison/bison/doc/bison.texinfo,v
retrieving revision 1.83
diff -p -u -r1.83 bison.texinfo
--- doc/bison.texinfo   15 Nov 2002 16:42:16 -0000      1.83
+++ doc/bison.texinfo   15 Nov 2002 20:24:04 -0000
@@ -1373,7 +1373,7 @@ main (void)
 
 When @code{yyparse} detects a syntax error, it calls the error reporting
 function @code{yyerror} to print an error message (usually but not
-always @code{"parse error"}).  It is up to the programmer to supply
+always @code{"syntax error"}).  It is up to the programmer to supply
 @code{yyerror} (@pxref{Interface, ,Parser C-Language Interface}), so
 here is the definition we will use:
 
@@ -1583,7 +1583,7 @@ line:     '\n'
 @end example
 
 This addition to the grammar allows for simple error recovery in the
-event of a parse error.  If an expression that cannot be evaluated is
+event of a syntax error.  If an expression that cannot be evaluated is
 read, the error will be recognized by the third rule for @code{line},
 and parsing will continue.  (The @code{yyerror} function is still called
 upon to print its message as well.)  The action executes the statement
@@ -3671,7 +3671,7 @@ Generate the code processing the locatio
 ,Special Features for Use in Actions}).  This mode is enabled as soon as
 the grammar uses the special @samp{@@@var{n}} tokens, but if your
 grammar does not use it, using @samp{%locations} allows for more
-accurate parse error messages.
+accurate syntax error messages.
 @end deffn
 
 @deffn {Directive} %name-prefix="@var{prefix}"
@@ -4134,7 +4134,7 @@ int yyparse (int *nastiness, int *random
 @cindex parse error
 @cindex syntax error
 
-The Bison parser detects a @dfn{parse error} or @dfn{syntax error}
+The Bison parser detects a @dfn{syntax error} or @dfn{parse error}
 whenever it reads a token which cannot satisfy any syntax rule.  An
 action in the grammar can also explicitly proclaim an error, using the
 macro @code{YYERROR} (@pxref{Action Features, ,Special Features for Use
@@ -4143,14 +4143,14 @@ in Actions}).
 The Bison parser expects to report the error by calling an error
 reporting function named @code{yyerror}, which you must supply.  It is
 called by @code{yyparse} whenever a syntax error is found, and it
-receives one argument.  For a parse error, the string is normally
address@hidden@code{"parse error"}}.
+receives one argument.  For a syntax error, the string is normally
address@hidden@code{"syntax error"}}.
 
 @findex %error-verbose
 If you invoke the directive @code{%error-verbose} in the Bison
 declarations section (@pxref{Bison Declarations, ,The Bison Declarations
 Section}), then Bison provides a more verbose and specific error message
-string instead of just plain @address@hidden"parse error"}}.
+string instead of just plain @address@hidden"syntax error"}}.
 
 The parser can detect one other kind of error: stack overflow.  This
 happens when the input contains constructions that are very deeply
@@ -5156,7 +5156,7 @@ provided which addresses this issue.
 @cindex error recovery
 @cindex recovery from errors
 
-It is not usually acceptable to have a program terminate on a parse
+It is not usually acceptable to have a program terminate on a syntax
 error.  For example, a compiler should recover sufficiently to parse the
 rest of the input file and check it for errors; a calculator should accept
 another expression.
@@ -5259,7 +5259,7 @@ this is unacceptable, then the macro @co
 this token.  Write the statement @samp{yyclearin;} in the error rule's
 action.
 
-For example, suppose that on a parse error, an error handling routine is
+For example, suppose that on a syntax error, an error handling routine is
 called that advances the input stream to some point where parsing should
 once again commence.  The next symbol returned by the lexical scanner is
 probably correct.  The previous look-ahead token ought to be discarded
@@ -5646,7 +5646,7 @@ after having reduced a rule that produce
 flow jumps to state 2.  If there is no such transition on a nonterminal
 symbol, and the lookahead is a @code{NUM}, then this token is shifted on
 the parse stack, and the control flow jumps to state 1.  Any other
-lookahead triggers a parse error.''
+lookahead triggers a syntax error.''
 
 @cindex core, item set
 @cindex item set core
@@ -5714,7 +5714,7 @@ because of the item @samp{exp -> exp . '
 @samp{+}, it will be shifted on the parse stack, and the automaton
 control will jump to state 4, corresponding to the item @samp{exp -> exp
 '+' . exp}.  Since there is no default action, any other token than
-those listed above will trigger a parse error.
+those listed above will trigger a syntax error.
 
 The state 3 is named the @dfn{final state}, or the @dfn{accepting
 state}:
@@ -6300,7 +6300,7 @@ The predefined token onto which all unde
 A token name reserved for error recovery.  This token may be used in
 grammar rules so as to allow the Bison parser to recognize an error in
 the grammar without halting the process.  In effect, a sentence
-containing an error may be recognized as valid.  On a parse error, the
+containing an error may be recognized as valid.  On a syntax error, the
 token @code{error} becomes the current look-ahead token.  Actions
 corresponding to @code{error} are then executed, and the look-ahead
 token is reset to the token that originally caused the violation.
@@ -6415,7 +6415,7 @@ symbols and parser action.  @xref{Tracin
 
 @deffn {Macro} yyerrok
 Macro to cause parser to recover immediately to its normal mode
-after a parse error.  @xref{Error Recovery}.
+after a syntax error.  @xref{Error Recovery}.
 @end deffn
 
 @deffn {Function} yyerror
@@ -6448,7 +6448,7 @@ variable within @code{yyparse}, and its 
 @end deffn
 
 @deffn {Variable} yynerrs
-Global variable which Bison increments each time there is a parse error.
+Global variable which Bison increments each time there is a syntax error.
 (In a pure parser, it is a local variable within @code{yyparse}.)
 @xref{Error Reporting, ,The Error Reporting Function @code{yyerror}}.
 @end deffn
@@ -6715,10 +6715,6 @@ A grammar symbol standing for a grammati
 be expressed through rules in terms of smaller constructs; in other
 words, a construct that is not a token.  @xref{Symbols}.
 
address@hidden Parse error
-An error encountered during parsing of an input stream due to invalid
-syntax.  @xref{Error Recovery}.
-
 @item Parser
 A function that recognizes valid sentences of a language by analyzing
 the syntax structure of a set of tokens passed to it from a lexical
@@ -6770,6 +6766,10 @@ first nonterminal symbol in a language s
 A data structure where symbol names and associated data are stored
 during parsing to allow for recognition and use of existing
 information in repeated uses of a symbol.  @xref{Multi-function Calc}.
+
address@hidden Syntax error
+An error encountered during parsing of an input stream due to invalid
+syntax.  @xref{Error Recovery}.
 
 @item Token
 A basic, grammatically indivisible unit of a language.  The symbol
Index: src/conflicts.c
===================================================================
RCS file: /cvsroot/bison/bison/src/conflicts.c,v
retrieving revision 1.95
diff -p -u -r1.95 conflicts.c
--- src/conflicts.c     22 Oct 2002 04:41:04 -0000      1.95
+++ src/conflicts.c     15 Nov 2002 20:24:05 -0000
@@ -252,7 +252,7 @@ resolve_sr_conflict (state_t *state, int
 | Solve the S/R conflicts of STATE using the                         |
 | precedence/associativity, and flag it inconsistent if it still has |
 | conflicts.  ERRS can be used as storage to compute the list of     |
-| lookaheads on which this STATE raises a parse error (%nonassoc).   |
+| lookaheads on which this STATE raises a syntax error (%nonassoc).  |
 `-------------------------------------------------------------------*/
 
 static void
@@ -302,7 +302,7 @@ void
 conflicts_solve (void)
 {
   state_number_t i;
-  /* List of lookaheads on which we explicitly raise a parse error.  */
+  /* List of lookaheads on which we explicitly raise a syntax error.  */
   symbol_t **errs = XMALLOC (symbol_t *, ntokens + 1);
 
   conflicts = XCALLOC (char, nstates);
Index: src/parse-gram.y
===================================================================
RCS file: /cvsroot/bison/bison/src/parse-gram.y,v
retrieving revision 1.29
diff -p -u -r1.29 parse-gram.y
--- src/parse-gram.y    15 Nov 2002 16:42:16 -0000      1.29
+++ src/parse-gram.y    15 Nov 2002 20:24:05 -0000
@@ -40,7 +40,7 @@
 #include "reader.h"
 #include "conflicts.h"
 
-/* Produce verbose parse errors.  */
+/* Produce verbose syntax errors.  */
 #define YYERROR_VERBOSE 1
 #define YYLLOC_DEFAULT(Current, Rhs, N)                        \
 do {                                                   \
@@ -64,7 +64,7 @@ do {                                                  \
    correctly typed access to it.  */
 #define yycontrol ((gram_control_t *) gram_control)
 
-/* Request detailed parse error messages, and pass them to GRAM_ERROR.
+/* Request detailed syntax error messages, and pass them to GRAM_ERROR.
    FIXME: depends on the undocumented availability of YYLLOC.t */
 #undef  yyerror
 #define yyerror(Msg) \
Index: src/tables.c
===================================================================
RCS file: /cvsroot/bison/bison/src/tables.c,v
retrieving revision 1.12
diff -p -u -r1.12 tables.c
--- src/tables.c        12 Nov 2002 08:30:47 -0000      1.12
+++ src/tables.c        15 Nov 2002 20:24:05 -0000
@@ -82,7 +82,7 @@ static base_t *width = NULL;
 /* For a given state, N = ACTROW[SYMBOL]:
 
    If N = 0, stands for `run the default action'.
-   If N = MIN, stands for `raise a parse error'.
+   If N = MIN, stands for `raise a syntax error'.
    If N > 0, stands for `shift SYMBOL and go to n'.
    If N < 0, stands for `reduce -N'.  */
 typedef short action_t;
@@ -116,7 +116,7 @@ static int conflict_list_free;
 static size_t table_size = 32768;
 base_t *table = NULL;
 base_t *check = NULL;
-/* The value used in TABLE to denote explicit parse errors
+/* The value used in TABLE to denote explicit syntax errors
    (%nonassoc), a negative infinite.  First defaults to ACTION_MIN,
    but in order to keep small tables, renumbered as TABLE_ERROR, which
    is the smallest (non error) value minus 1.  */
Index: src/tables.h
===================================================================
RCS file: /cvsroot/bison/bison/src/tables.h,v
retrieving revision 1.4
diff -p -u -r1.4 tables.h
--- src/tables.h        21 Oct 2002 05:30:50 -0000      1.4
+++ src/tables.h        15 Nov 2002 20:24:05 -0000
@@ -105,7 +105,7 @@ extern int conflict_list_cnt;
 
 extern base_t *table;
 extern base_t *check;
-/* The value used in TABLE to denote explicit parse errors
+/* The value used in TABLE to denote explicit syntax errors
    (%nonassoc), a negative infinite.  */
 extern base_t table_ninf;
 
Index: tests/actions.at
===================================================================
RCS file: /cvsroot/bison/bison/tests/actions.at,v
retrieving revision 1.20
diff -p -u -r1.20 actions.at
--- tests/actions.at    14 Nov 2002 09:58:01 -0000      1.20
+++ tests/actions.at    15 Nov 2002 20:24:05 -0000
@@ -322,7 +322,7 @@ thing(address@hidden): 'x'(address@hidden)
 sending: 'x' (value = 2, line 20)
 thing(address@hidden): 'x'(address@hidden)
 sending: 'x' (value = 3, line 30)
-30: parse error, unexpected 'x', expecting ';'
+30: syntax error, unexpected 'x', expecting ';'
 Freeing nterm thing (address@hidden)
 Freeing nterm thing (address@hidden)
 Freeing nterm thing (address@hidden)
@@ -344,7 +344,7 @@ thing(address@hidden): 'x'(address@hidden)
 sending: ';' (value = 11, line 110)
 line(address@hidden): thing(address@hidden) ';'
 sending: 'y' (value = 12, line 120)
-120: parse error, unexpected $undefined, expecting $end or 'x'
+120: syntax error, unexpected $undefined, expecting $end or 'x'
 sending: EOF
 Freeing nterm line (address@hidden)
 Freeing nterm line (address@hidden)
Index: tests/calc.at
===================================================================
RCS file: /cvsroot/bison/bison/tests/calc.at,v
retrieving revision 1.44
diff -p -u -r1.44 calc.at
--- tests/calc.at       15 Nov 2002 16:42:16 -0000      1.44
+++ tests/calc.at       15 Nov 2002 20:24:05 -0000
@@ -353,7 +353,7 @@ m4_bmatch([$1],
 #                      [NUM-DEBUG-LINES],
 #                      [VERBOSE-AND-LOCATED-ERROR-MESSAGE])
 # ---------------------------------------------------------
-# Run `calc' on INPUT, and expect a `parse error' message.
+# Run `calc' on INPUT, and expect a `syntax error' message.
 #
 # If INPUT starts with a slash, it is used as absolute input file name,
 # otherwise as contents.
@@ -362,7 +362,7 @@ m4_bmatch([$1],
 # is correctly output on stderr.
 #
 # If BISON-OPTIONS contains `%error-verbose', then make sure the
-# IF-YYERROR-VERBOSE message is properly output after `parse error, '
+# IF-YYERROR-VERBOSE message is properly output after `syntax error, '
 # on STDERR.
 #
 # If BISON-OPTIONS contains `%debug' but not `%glr', then NUM-STDERR-LINES
@@ -406,7 +406,7 @@ AT_YYERROR_SEES_LOC_IF([],
 mv at-expout expout]])
 # 4. If error-verbose is not used, strip the`, unexpected....' part.
 m4_bmatch([$1], [%error-verbose], [],
-[[sed 's/parse error, .*$/parse error/' expout >at-expout
+[[sed 's/syntax error, .*$/syntax error/' expout >at-expout
 mv at-expout expout]])
 # 5. Check
 AT_CHECK([cat stderr], 0, [expout])
@@ -497,30 +497,30 @@ _AT_CHECK_CALC([$1],
 (2^2)^3 = 64],
                [486])
 
-# Some parse errors.
+# Some syntax errors.
 _AT_CHECK_CALC_ERROR([$1], [1], [0 0], [11],
-                     [1.3-1.4: parse error, unexpected "number"])
+                     [1.3-1.4: syntax error, unexpected "number"])
 _AT_CHECK_CALC_ERROR([$1], [1], [1//2], [15],
-                     [1.3-1.4: parse error, unexpected '/', expecting "number" 
or '-' or '('])
+                     [1.3-1.4: syntax error, unexpected '/', expecting 
"number" or '-' or '('])
 _AT_CHECK_CALC_ERROR([$1], [1], [error], [4],
-                     [1.1-1.2: parse error, unexpected $undefined, expecting 
"number" or '-' or '\n' or '('])
+                     [1.1-1.2: syntax error, unexpected $undefined, expecting 
"number" or '-' or '\n' or '('])
 _AT_CHECK_CALC_ERROR([$1], [1], [1 = 2 = 3], [22],
-                     [1.7-1.8: parse error, unexpected '='])
+                     [1.7-1.8: syntax error, unexpected '='])
 _AT_CHECK_CALC_ERROR([$1], [1],
                      [
 +1],
                      [14],
-                     [2.1-2.2: parse error, unexpected '+'])
+                     [2.1-2.2: syntax error, unexpected '+'])
 # Exercise error messages with EOF: work on an empty file.
 _AT_CHECK_CALC_ERROR([$1], [1], [/dev/null], [4],
-                     [1.1-1.2: parse error, unexpected "end of input", 
expecting "number" or '-' or '\n' or '('])
+                     [1.1-1.2: syntax error, unexpected "end of input", 
expecting "number" or '-' or '\n' or '('])
 
 # Exercise the error token: without it, we die at the first error,
 # hence be sure i. to have several errors, ii. to test the action
 # associated to `error'.
 _AT_CHECK_CALC_ERROR([$1], [0], [(1 ++ 2) + (0 0) = 1], [82],
-[1.5-1.6: parse error, unexpected '+', expecting "number" or '-' or '('
-1.15-1.16: parse error, unexpected "number"
+[1.5-1.6: syntax error, unexpected '+', expecting "number" or '-' or '('
+1.15-1.16: syntax error, unexpected "number"
 calc: error: 0 != 1])
 
 AT_CHECK_POPDEFS
Index: tests/conflicts.at
===================================================================
RCS file: /cvsroot/bison/bison/tests/conflicts.at,v
retrieving revision 1.20
diff -p -u -r1.20 conflicts.at
--- tests/conflicts.at  14 Nov 2002 09:58:01 -0000      1.20
+++ tests/conflicts.at  15 Nov 2002 20:24:05 -0000
@@ -108,16 +108,16 @@ AT_PARSER_CHECK([./input '0<0'])
 # no one has ever spotted it!  The messages are *wrong*: there should
 # be nothing there, it should be expected eof.
 AT_PARSER_CHECK([./input '0<0<0'], [1], [],
-         [parse error, unexpected '<', expecting '<' or '>'
+         [syntax error, unexpected '<', expecting '<' or '>'
 ])
 
 AT_PARSER_CHECK([./input '0>0'])
 AT_PARSER_CHECK([./input '0>0>0'], [1], [],
-         [parse error, unexpected '>', expecting '<' or '>'
+         [syntax error, unexpected '>', expecting '<' or '>'
 ])
 
 AT_PARSER_CHECK([./input '0<0>0'], [1], [],
-         [parse error, unexpected '>', expecting '<' or '>'
+         [syntax error, unexpected '>', expecting '<' or '>'
 ])
 
 AT_CLEANUP
Index: tests/cxx-type.at
===================================================================
RCS file: /cvsroot/bison/bison/tests/cxx-type.at,v
retrieving revision 1.10
diff -p -u -r1.10 cxx-type.at
--- tests/cxx-type.at   14 Nov 2002 09:58:01 -0000      1.10
+++ tests/cxx-type.at   15 Nov 2002 20:24:05 -0000
@@ -241,11 +241,11 @@ z q +
 ]])
 
 m4_define([_AT_GLR_STDERR],
-[[parse error
+[[syntax error
 ]])
 
 m4_define([_AT_VERBOSE_GLR_STDERR],
-[[parse error, unexpected ID, expecting '=' or '+' or ')'
+[[syntax error, unexpected ID, expecting '=' or '+' or ')'
 ]])
 
 ## ---------------------------------------------------- ##
Index: tests/regression.at
===================================================================
RCS file: /cvsroot/bison/bison/tests/regression.at,v
retrieving revision 1.75
diff -p -u -r1.75 regression.at
--- tests/regression.at 14 Nov 2002 09:58:01 -0000      1.75
+++ tests/regression.at 15 Nov 2002 20:24:05 -0000
@@ -298,7 +298,7 @@ input.y:5.1-17: invalid directive: `%a-d
 input.y:6.1: invalid character: `%'
 input.y:6.2: invalid character: `-'
 input.y:7.1-8.0: missing `%}' at end of file
-input.y:7.1-8.0: parse error, unexpected "%{...%}", expecting ";" or "|"
+input.y:7.1-8.0: syntax error, unexpected "%{...%}", expecting ";" or "|"
 ]])
 
 AT_CLEANUP




reply via email to

[Prev in Thread] Current Thread [Next in Thread]