summaryrefslogtreecommitdiff
path: root/lib/coderay/scanners/ruby/patterns.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/coderay/scanners/ruby/patterns.rb')
-rw-r--r--lib/coderay/scanners/ruby/patterns.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/coderay/scanners/ruby/patterns.rb b/lib/coderay/scanners/ruby/patterns.rb
index 51ceba3..fc6ce56 100644
--- a/lib/coderay/scanners/ruby/patterns.rb
+++ b/lib/coderay/scanners/ruby/patterns.rb
@@ -142,7 +142,7 @@ module Scanners
| #{CHARACTER}
)
/x
- VALUE_EXPECTING_KEYWORDS = WordList.new.add(%w[
+ KEYWORDS_EXPECTING_VALUE = WordList.new.add(%w[
and end in or unless begin
defined? ensure redo super until
break do next rescue then
@@ -182,7 +182,7 @@ module Scanners
STRING_PATTERN = Hash.new do |h, k|
delim, interpreted = *k
- delim_pattern = Regexp.escape(delim)
+ delim_pattern = Regexp.escape(delim.dup) # dup: Fix for x86_64-linux Ruby
if closing_paren = CLOSING_PAREN[delim]
delim_pattern = delim_pattern[0..-1] if defined? JRUBY_VERSION # JRuby fix
delim_pattern << Regexp.escape(closing_paren)