diff --git a/lib/coderay/scanners/ruby.rb b/lib/coderay/scanners/ruby.rb index 5b8de42f..a9a41149 100644 --- a/lib/coderay/scanners/ruby.rb +++ b/lib/coderay/scanners/ruby.rb @@ -257,7 +257,7 @@ def scan_tokens encoder, options end unless unicode # check for unicode - $DEBUG_BEFORE, $DEBUG = $DEBUG, false + debug_before, $DEBUG = $DEBUG, false begin if check(/./mu).size > 1 # seems like we should try again with unicode @@ -266,7 +266,7 @@ def scan_tokens encoder, options rescue # bad unicode char; use getch ensure - $DEBUG = $DEBUG_BEFORE + $DEBUG = debug_before end next if unicode end