1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[ruby/irb] Suppress "shadowing outer" warning

https://github.com/ruby/irb/commit/8b83fbef69
This commit is contained in:
aycabta 2020-12-23 21:18:48 +09:00
parent 684649ea05
commit 31bd172185

View file

@ -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