bison-patches
[Top][All Lists]
Advanced

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

[PATCH 4/5] YYLEX_PARAM: drop support


From: Akim Demaille
Subject: [PATCH 4/5] YYLEX_PARAM: drop support
Date: Wed, 26 Dec 2012 10:40:17 +0100

* data/yacc.c, doc/bison.texi: Remove YYLEX_PARAM support.
* NEWS: Document it.
---
 NEWS           | 11 +++++++----
 data/yacc.c    |  6 +-----
 doc/bison.texi |  7 -------
 3 files changed, 8 insertions(+), 16 deletions(-)

diff --git a/NEWS b/NEWS
index 39c812e..d4f8a75 100644
--- a/NEWS
+++ b/NEWS
@@ -6,10 +6,13 @@ GNU Bison NEWS
 
 *** Obsolete features
 
-  Support for YYFAIL is removed (deprecated in Bison 2.4.2).
-  Support for yystype and yyltype (instead of YYSTYPE and YYLTYPE)
-  is removed (deprecated in Bison 1.875).
-  Support for YYPARSE_PARAM is removed (deprecated in Bison 1.875).
+  Support for YYFAIL is removed (deprecated in Bison 2.4.2): use YYERROR.
+
+  Support for yystype and yyltype is removed (deprecated in Bison 1.875):
+  use YYSTYPE and YYLTYPE.
+
+  Support for YYLEX_PARAM and YYPARSE_PARAM is removed (deprecated in Bison
+  1.875): use %lex-param, %parse-param, or %param.
 
 ** Warnings
 
diff --git a/data/yacc.c b/data/yacc.c
index b64ccdf..f75f9d5 100644
--- a/data/yacc.c
+++ b/data/yacc.c
@@ -687,11 +687,7 @@ while (0)
 ]b4_yy_location_print_define[
 
 /* YYLEX -- calling `yylex' with the right arguments.  */
-#ifdef YYLEX_PARAM
-# define YYLEX yylex (]b4_pure_if([&yylval[]b4_locations_if([, &yylloc]), 
])[YYLEX_PARAM)
-#else
-# define YYLEX ]b4_function_call([yylex], [int], b4_lex_param)[
-#endif
+#define YYLEX ]b4_function_call([yylex], [int], b4_lex_param)[
 
 /* Enable debugging if requested.  */
 #if ]b4_api_PREFIX[DEBUG
diff --git a/doc/bison.texi b/doc/bison.texi
index f738f51..bc7b167 100644
--- a/doc/bison.texi
+++ b/doc/bison.texi
@@ -12604,13 +12604,6 @@ the next token.  @xref{Lexical, ,The Lexical Analyzer 
Function
 @code{yylex}}.
 @end deffn
 
address@hidden {Macro} YYLEX_PARAM
-An obsolete macro for specifying an extra argument (or list of extra
-arguments) for @code{yyparse} to pass to @code{yylex}.  The use of this
-macro is deprecated, and is supported only for Yacc like parsers.
address@hidden Calling,, Calling Conventions for Pure Parsers}.
address@hidden deffn
-
 @deffn {Variable} yylloc
 External variable in which @code{yylex} should place the line and column
 numbers associated with a token.  (In a pure parser, it is a local
-- 
1.8.0.2




reply via email to

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