summaryrefslogtreecommitdiff
path: root/lib/coderay/scanners/ruby.rb
diff options
context:
space:
mode:
authormurphy <murphy@rubychan.de>2006-10-18 21:48:17 +0000
committermurphy <murphy@rubychan.de>2006-10-18 21:48:17 +0000
commit3f5cc3ae69ecad6a6909aad4b553eb958241dd14 (patch)
treef488993bf2c9761c6f98ca5ddd55497f6fa8f832 /lib/coderay/scanners/ruby.rb
parent26a698230e2e502bfe90392ae034409506ca3cdc (diff)
downloadcoderay-3f5cc3ae69ecad6a6909aad4b553eb958241dd14.tar.gz
Ruby scanner: #{...} delimiters are now :inline_delimiter to solve CSS problem.
New token: :inline_delimiter Scanner tests suite revamped: colorization, split up into methods.
Diffstat (limited to 'lib/coderay/scanners/ruby.rb')
-rw-r--r--lib/coderay/scanners/ruby.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/coderay/scanners/ruby.rb b/lib/coderay/scanners/ruby.rb
index d15af0d..def5960 100644
--- a/lib/coderay/scanners/ruby.rb
+++ b/lib/coderay/scanners/ruby.rb
@@ -97,7 +97,7 @@ module Scanners
state = :initial
depth = 1
tokens << [:open, :inline]
- tokens << [match + getch, :delimiter]
+ tokens << [match + getch, :inline_delimiter]
when ?$, ?@
tokens << [match, :escape]
last_state = state # scan one token as normal code, then return here
@@ -189,7 +189,7 @@ module Scanners
depth -= 1
if depth == 0 # closing brace of inline block reached
state, depth, heredocs = inline_block_stack.pop
- tokens << [match, :delimiter]
+ tokens << [match, :inline_delimiter]
kind = :inline
match = :close
end