From f7db1affd10767d729866e95c02ffb26266829ab Mon Sep 17 00:00:00 2001 From: yui-knk Date: Fri, 23 Sep 2022 23:01:55 +0900 Subject: Set default %printer for NODE nterms Before: ``` Reducing stack by rule 639 (line 5062): $1 = token "integer literal" (1.0-1.1: 1) -> $$ = nterm simple_numeric (1.0-1.1: ) ``` After: ``` Reducing stack by rule 641 (line 5078): $1 = token "integer literal" (1.0-1.1: 1) -> $$ = nterm simple_numeric (1.0-1.1: NODE_LIT) ``` `"<*>"` is supported by Bison 2.3b (2008-05-27) or later. https://git.savannah.gnu.org/cgit/bison.git/commit/?id=12e3584054c16ab255672c07af0ffc7bb220e8bc Therefore developers need to install Bison 2.3b+ to build ruby from source codes if their Bison is older. Minimum version requirement for Bison is changed to 3.0. See: https://bugs.ruby-lang.org/issues/19068 [Feature #19068] --- ext/ripper/tools/preproc.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ext/ripper/tools') diff --git a/ext/ripper/tools/preproc.rb b/ext/ripper/tools/preproc.rb index b838a78db7..cd85a5da61 100644 --- a/ext/ripper/tools/preproc.rb +++ b/ext/ripper/tools/preproc.rb @@ -47,7 +47,7 @@ def prelude(f, out) when /\A%%/ out << "%%\n" return - when /\A%token/ + when /\A%token/, /\A} / out << line.sub(/<\w+>/, '') when /\A%type/ out << line.sub(/<\w+>/, '') -- cgit v1.2.3