summaryrefslogtreecommitdiff
path: root/data/skeletons/lalr1.cc
diff options
context:
space:
mode:
authorAkim Demaille <akim.demaille@gmail.com>2020-04-12 08:14:12 +0200
committerAkim Demaille <akim.demaille@gmail.com>2020-04-12 13:56:44 +0200
commitecf5cb7e0e1f7d025dee1e40cf345d5728dab2b2 (patch)
treeb06fd36b3165c6c12e8db7aa7b8cbe843e66a542 /data/skeletons/lalr1.cc
parente50de09886bfdf4febb75accdd1549952787b5e0 (diff)
downloadbison-ecf5cb7e0e1f7d025dee1e40cf345d5728dab2b2.tar.gz
c++: remove the yy prefix from some functions
yy::parser features a parse() function, not a yyparse() one. * data/skeletons/lalr1.cc (yyreport_syntax_error) (context::yyexpected_tokens): Rename as... (report_syntax_error, context::expected_tokens): these.
Diffstat (limited to 'data/skeletons/lalr1.cc')
-rw-r--r--data/skeletons/lalr1.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/data/skeletons/lalr1.cc b/data/skeletons/lalr1.cc
index 4387fbfc..13fab5bf 100644
--- a/data/skeletons/lalr1.cc
+++ b/data/skeletons/lalr1.cc
@@ -247,7 +247,7 @@ m4_define([b4_shared_declarations],
/// Put in YYARG at most YYARGN of the expected tokens, and return the
/// number of tokens stored in YYARG. If YYARG is null, return the
/// number of expected tokens (guaranteed to be less than YYNTOKENS).
- int yyexpected_tokens (symbol_kind_type yyarg[], int yyargn) const;
+ int expected_tokens (symbol_kind_type yyarg[], int yyargn) const;
private:
const ]b4_parser_class[& yyparser_;
@@ -276,7 +276,7 @@ m4_define([b4_shared_declarations],
[custom], [[
/// Report a syntax error
/// \param yyctx the context in which the error occurred.
- void yyreport_syntax_error (const context& yyctx) const;]],
+ void report_syntax_error (const context& yyctx) const;]],
[detailed\|verbose], [[
/// The arguments of the error message.
int yy_syntax_error_arguments_ (const context& yyctx,
@@ -1074,7 +1074,7 @@ b4_dollar_popdef])[]dnl
error (]b4_join(b4_locations_if([yyla.location]), [[YY_MOVE (msg)]])[);]],
[custom], [[
context yyctx (*this, yyla);
- yyreport_syntax_error (yyctx);]],
+ report_syntax_error (yyctx);]],
[[
context yyctx (*this, yyla);
std::string msg = yysyntax_error_ (yyctx);
@@ -1230,7 +1230,7 @@ b4_dollar_popdef])[]dnl
{}
int
- ]b4_parser_class[::context::yyexpected_tokens (symbol_kind_type yyarg[], int yyargn) const
+ ]b4_parser_class[::context::expected_tokens (symbol_kind_type yyarg[], int yyargn) const
{
// Actual number of expected tokens
int yycount = 0;
@@ -1462,7 +1462,7 @@ b4_dollar_popdef])[]dnl
{
if (yyarg)
yyarg[0] = yyctx.token ();
- int yyn = yyctx.yyexpected_tokens (yyarg ? yyarg + 1 : yyarg, yyargn - 1);
+ int yyn = yyctx.expected_tokens (yyarg ? yyarg + 1 : yyarg, yyargn - 1);
return yyn + 1;
}
return 0;