aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <unknown>2010-10-20 14:53:55 +1100
committernyamatongwe <unknown>2010-10-20 14:53:55 +1100
commit85c776304cdd0a3a48f1a5dba42d89cea9665d9a (patch)
treeabcf521db74366078fd86224dc946a61ee88e373
parent52e2182d891107cfbf8f00cd902b34b812ddc2ce (diff)
downloadscintilla-mirror-85c776304cdd0a3a48f1a5dba42d89cea9665d9a.tar.gz
Treat all dots as operators in ranges 1..2 and 1...2 rather than
treating the first dot as part of a number. Fixes part of bug #3058496 and patch came from bug #2093767.
-rw-r--r--lexers/LexRuby.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/lexers/LexRuby.cxx b/lexers/LexRuby.cxx
index af8535243..a77ff13ee 100644
--- a/lexers/LexRuby.cxx
+++ b/lexers/LexRuby.cxx
@@ -1129,6 +1129,10 @@ static void ColouriseRbDoc(unsigned int startPos, int length, int initStyle,
}
} else if (isSafeAlnumOrHigh(ch) || ch == '_') {
// Keep going
+ } else if (ch == '.' && chNext == '.') {
+ ++numDots;
+ styler.ColourTo(i - 1, state);
+ redo_char(i, ch, chNext, chNext2, state); // pass by ref
} else if (ch == '.' && ++numDots == 1) {
// Keep going
} else {