From 31bd17218515a20cf46951018d413b739935beba Mon Sep 17 00:00:00 2001 From: aycabta Date: Wed, 23 Dec 2020 21:18:48 +0900 Subject: [PATCH] [ruby/irb] Suppress "shadowing outer" warning https://github.com/ruby/irb/commit/8b83fbef69 --- lib/irb/ruby-lex.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/irb/ruby-lex.rb b/lib/irb/ruby-lex.rb index b07027898c..9914aece5e 100644 --- a/lib/irb/ruby-lex.rb +++ b/lib/irb/ruby-lex.rb @@ -557,7 +557,7 @@ class RubyLex end_type << :on_regexp_end when :on_symbeg acceptable_single_tokens = %i{on_ident on_const on_op on_cvar on_ivar on_gvar on_kw} - if (i + 1) < tokens.size and acceptable_single_tokens.all?{ |t| tokens[i + 1][1] != t } + if (i + 1) < tokens.size and acceptable_single_tokens.all?{ |st| tokens[i + 1][1] != st } start_token << t end_type << :on_tstring_end end