Skip to content

Commit

Permalink
Ensure to restore $VERBOSE
Browse files Browse the repository at this point in the history
  • Loading branch information
nobu committed Jan 5, 2021
1 parent 8a19800 commit cef474a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/irb/color.rb
Expand Up @@ -192,6 +192,7 @@ def scan(code, allow_last_error:)
end
end
end
ensure
$VERBOSE = verbose
end

Expand Down
3 changes: 2 additions & 1 deletion lib/irb/ruby-lex.rb
Expand Up @@ -139,8 +139,9 @@ def ripper_lex_without_warning(code)
tokens = lexer.parse
end
end
$VERBOSE = verbose
tokens
ensure
$VERBOSE = verbose
end

def find_prev_spaces(line_index)
Expand Down

0 comments on commit cef474a

Please sign in to comment.