aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2001-01-25 23:45:59 +0000
committernyamatongwe <devnull@localhost>2001-01-25 23:45:59 +0000
commitef5b4f4ee4106324df53b6f492dfdca95a5e7a25 (patch)
tree4abb0b475e2ea00f9d78391b47c64663d050a60c
parent2f2ac68fd426bc84adb581720868d33781ddc47b (diff)
downloadscintilla-mirror-ef5b4f4ee4106324df53b6f492dfdca95a5e7a25.tar.gz
Patch from Steffen to handle $^W and ${"x"} as scalars.
Further change from Neil to avoid whitespace being included in scalars.
-rw-r--r--src/LexPerl.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/LexPerl.cxx b/src/LexPerl.cxx
index d22d90a6a..f5487492a 100644
--- a/src/LexPerl.cxx
+++ b/src/LexPerl.cxx
@@ -288,7 +288,14 @@ static void ColourisePerlDoc(unsigned int startPos, int length, int initStyle,
} else if (ch == '$') {
preferRE = false;
styler.ColourTo(i - 1, state);
- state = SCE_PL_SCALAR;
+ if ((chNext == '{') || isspacechar(chNext)) {
+ styler.ColourTo(i, SCE_PL_SCALAR);
+ } else {
+ state = SCE_PL_SCALAR;
+ i++;
+ ch = chNext;
+ chNext = chNext2;
+ }
} else if (ch == '@') {
preferRE = false;
styler.ColourTo(i - 1, state);