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

Supress duplicated warning

This commit is contained in:
Kazuki Tsujimoto 2019-05-28 01:30:15 +09:00 committed by aycabta
parent 9a68aba79f
commit b2b5ed1410

View file

@ -152,6 +152,7 @@ class RubyLex
end
begin # check if parser error are available
verbose, $VERBOSE = $VERBOSE, nil
RubyVM::InstructionSequence.compile(code)
rescue SyntaxError => e
case e.message
@ -199,6 +200,8 @@ class RubyLex
# method / f /
return false
end
ensure
$VERBOSE = verbose
end
last_lex_state = @tokens.last[3]