summaryrefslogtreecommitdiff
path: root/lib/coderay/scanners/ruby.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/coderay/scanners/ruby.rb')
-rw-r--r--lib/coderay/scanners/ruby.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/coderay/scanners/ruby.rb b/lib/coderay/scanners/ruby.rb
index 1ceb3d5..4cb1e58 100644
--- a/lib/coderay/scanners/ruby.rb
+++ b/lib/coderay/scanners/ruby.rb
@@ -213,7 +213,8 @@ module CodeRay module Scanners
state = DEF_NEW_STATE[match]
end
end
- fancy_allowed = regexp_allowed = REGEXP_ALLOWED[match]
+ ## experimental!
+ fancy_allowed = regexp_allowed = :set if REGEXP_ALLOWED[match] or check(/\s+(?:%\S|\/\S)/)
elsif match = scan(/ ['"] /mx)
tokens << [:open, :string]