From aa52464efd558010f4fa5ef5de68d8f684b637aa Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Fri, 10 May 2019 21:45:15 +0900 Subject: [PATCH] 15f45ae4d1 and 56528da3e broke the darwin environment. Revert "Propagate parser_params to rb_yytnamerr" This reverts commit 15f45ae4d12f14714ab3021b60887d8c7bf4b095. --- parse.y | 7 +++---- tool/ytab.sed | 2 -- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/parse.y b/parse.y index 60ca58f61e..fd0810987f 100644 --- a/parse.y +++ b/parse.y @@ -649,8 +649,8 @@ rb_strterm_mark(VALUE obj) } #endif -#define yytnamerr(yyres, yystr) (YYSIZE_T)rb_yytnamerr(p, yyres, yystr) -size_t rb_yytnamerr(struct parser_params *p, char *yyres, const char *yystr); +#define yytnamerr(yyres, yystr) (YYSIZE_T)rb_yytnamerr(yyres, yystr) +size_t rb_yytnamerr(char *yyres, const char *yystr); #define TOKEN2ID(tok) ( \ tTOKEN_LOCAL_BEGIN<(tok)&&(tok) "`class' keyword" */ RUBY_FUNC_EXPORTED size_t -rb_yytnamerr(struct parser_params *p, char *yyres, const char *yystr) +rb_yytnamerr(char *yyres, const char *yystr) { - YYUSE(p); if (*yystr == '"') { size_t yyn = 0, bquote = 0; const char *yyp = yystr; diff --git a/tool/ytab.sed b/tool/ytab.sed index ac7e97107d..f7438077dc 100755 --- a/tool/ytab.sed +++ b/tool/ytab.sed @@ -67,8 +67,6 @@ a\ /^yy_reduce_print/,/^}/{ s/fprintf *(stderr,/YYFPRINTF (p,/g } -s/^yysyntax_error (/&struct parser_params *p, / -s/YYSYNTAX_ERROR yysyntax_error (/&p, / s/\( YYFPRINTF *(\)yyoutput,/\1p,/ s/\( YYFPRINTF *(\)yyo,/\1p,/ s/\( YYFPRINTF *(\)stderr,/\1p,/