bison-patches
[Top][All Lists]
Advanced

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

[PATCH 1/3] c++: stop referring to YYSTYPE in yylex


From: Akim Demaille
Subject: [PATCH 1/3] c++: stop referring to YYSTYPE in yylex
Date: Mon, 1 Feb 2021 06:34:37 +0100

* data/skeletons/glr2.cc, data/skeletons/lalr1.cc (b4_lex): Don't
refer to YYSTYPE, but to value_type.
Note that this is "symbolic" in the sense that these values are never
used by b4_function_call.
---
 data/skeletons/glr2.cc  | 4 ++--
 data/skeletons/lalr1.cc | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/data/skeletons/glr2.cc b/data/skeletons/glr2.cc
index c33ce9c8b..e53de88af 100644
--- a/data/skeletons/glr2.cc
+++ b/data/skeletons/glr2.cc
@@ -181,8 +181,8 @@ m4_define([b4_lex],
 [b4_function_call([yylex],
                   [symbol_type], m4_ifdef([b4_lex_param], b4_lex_param))],
 [b4_function_call([yylex], [int],
-                  [b4_api_PREFIX[STYPE*], [&this->yylval]][]dnl
-b4_locations_if([, [[location*], [&this->yylloc]]])dnl
+                  [[value_type *], [&this->yylval]][]dnl
+b4_locations_if([, [[location_type *], [&this->yylloc]]])dnl
 m4_ifdef([b4_lex_param], [, ]b4_lex_param))])])
 
 
diff --git a/data/skeletons/lalr1.cc b/data/skeletons/lalr1.cc
index 63d80dcd0..56b23f6fb 100644
--- a/data/skeletons/lalr1.cc
+++ b/data/skeletons/lalr1.cc
@@ -153,8 +153,8 @@ m4_define([b4_lex],
 [b4_function_call([yylex],
                   [symbol_type], m4_ifdef([b4_lex_param], b4_lex_param))],
 [b4_function_call([yylex], [int],
-                  [b4_api_PREFIX[STYPE*], [&yyla.value]][]dnl
-b4_locations_if([, [[location*], [&yyla.location]]])dnl
+                  [[value_type *], [&yyla.value]][]dnl
+b4_locations_if([, [[location_type *], [&yyla.location]]])dnl
 m4_ifdef([b4_lex_param], [, ]b4_lex_param))])])
 
 
-- 
2.30.0




reply via email to

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