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:
parent
9a68aba79f
commit
b2b5ed1410
1 changed files with 3 additions and 0 deletions
|
@ -152,6 +152,7 @@ class RubyLex
|
||||||
end
|
end
|
||||||
|
|
||||||
begin # check if parser error are available
|
begin # check if parser error are available
|
||||||
|
verbose, $VERBOSE = $VERBOSE, nil
|
||||||
RubyVM::InstructionSequence.compile(code)
|
RubyVM::InstructionSequence.compile(code)
|
||||||
rescue SyntaxError => e
|
rescue SyntaxError => e
|
||||||
case e.message
|
case e.message
|
||||||
|
@ -199,6 +200,8 @@ class RubyLex
|
||||||
# method / f /
|
# method / f /
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
ensure
|
||||||
|
$VERBOSE = verbose
|
||||||
end
|
end
|
||||||
|
|
||||||
last_lex_state = @tokens.last[3]
|
last_lex_state = @tokens.last[3]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue