mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 04:13:03 +00:00
d: change the name of the custom error message function to reportSyntaxError
Changed from syntax_error to reportSyntaxError to be similar to the Java parser. * data/skeletons/lalr1.d: Change the function name. * doc/bison.texi: Document it. * tests/local.at: Adjust.
This commit is contained in:
committed by
Akim Demaille
parent
5945da031e
commit
0e51f6146a
@@ -14026,7 +14026,7 @@ They should return new objects for each call, to avoid that all the symbol
|
||||
share the same Position boundaries.
|
||||
@end deftypemethod
|
||||
|
||||
@deftypemethod {Lexer} {void} syntax_error(@code{YYParser.Context} @var{ctx})
|
||||
@deftypemethod {Lexer} {void} reportSyntaxError(@code{YYParser.Context} @var{ctx})
|
||||
If you invoke @samp{%define parse.error custom} (@pxref{Bison
|
||||
Declarations}), then the parser no longer passes syntax error messages to
|
||||
@code{yyerror}, rather it delegates that task to the user by calling the
|
||||
@@ -14038,7 +14038,7 @@ Here is an example of a reporting function (@pxref{D Parser Context
|
||||
Interface}).
|
||||
|
||||
@example
|
||||
public void syntax_error(YYParser.Context ctx)
|
||||
public void reportSyntaxError(YYParser.Context ctx)
|
||||
@{
|
||||
stderr.write(ctx.getLocation(), ": syntax error");
|
||||
// Report the expected tokens.
|
||||
|
||||
Reference in New Issue
Block a user