diff options
author | nyamatongwe <devnull@localhost> | 2002-02-12 10:35:17 +0000 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2002-02-12 10:35:17 +0000 |
commit | a60206ecb6729cd1ee44a39aaf132cb60173b32d (patch) | |
tree | 3c82f9059fe7001e94745310b8eb4091a0d32bee /src/LexOthers.cxx | |
parent | 8fdc38b725ee9cc02900995e41fc9eb35305d611 (diff) | |
download | scintilla-mirror-a60206ecb6729cd1ee44a39aaf132cb60173b32d.tar.gz |
Minor fixes to lexers.
Diffstat (limited to 'src/LexOthers.cxx')
-rw-r--r-- | src/LexOthers.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/LexOthers.cxx b/src/LexOthers.cxx index efc4dafd6..55a30d564 100644 --- a/src/LexOthers.cxx +++ b/src/LexOthers.cxx @@ -131,7 +131,7 @@ static void ColouriseBatchDoc( styler.StartAt(startPos); styler.StartSegment(startPos); unsigned int linePos = 0, startLine = startPos; - for (unsigned int i = startPos; i <= startPos + length; i++) { + for (unsigned int i = startPos; i < startPos + length; i++) { lineBuffer[linePos++] = styler[i]; if (styler[i] == '\r' || styler[i] == '\n' || (linePos >= sizeof(lineBuffer) - 1)) { @@ -229,7 +229,7 @@ static void ColourisePropsDoc(unsigned int startPos, int length, int, WordList * styler.StartAt(startPos); styler.StartSegment(startPos); unsigned int linePos = 0, startLine = startPos; - for (unsigned int i = startPos; i <= startPos + length; i++) { + for (unsigned int i = startPos; i < startPos + length; i++) { lineBuffer[linePos++] = styler[i]; if ((styler[i] == '\r' && styler.SafeGetCharAt(i + 1) != '\n') || styler[i] == '\n' || @@ -296,9 +296,9 @@ static void ColouriseMakeLine( i++; } if (state == SCE_MAKE_IDENTIFIER) { - styler.ColourTo(endPos, SCE_MAKE_IDEOL); // Error, variable reference not ended + styler.ColourTo(endPos-1, SCE_MAKE_IDEOL); // Error, variable reference not ended } else { - styler.ColourTo(endPos, SCE_MAKE_DEFAULT); + styler.ColourTo(endPos-1, SCE_MAKE_DEFAULT); } } @@ -307,7 +307,7 @@ static void ColouriseMakeDoc(unsigned int startPos, int length, int, WordList *[ styler.StartAt(startPos); styler.StartSegment(startPos); unsigned int linePos = 0, startLine = startPos; - for (unsigned int i = startPos; i <= startPos + length; i++) { + for (unsigned int i = startPos; i < startPos + length; i++) { lineBuffer[linePos++] = styler[i]; if (styler[i] == '\r' || styler[i] == '\n' || (linePos >= sizeof(lineBuffer) - 1)) { lineBuffer[linePos] = '\0'; @@ -409,7 +409,7 @@ static void ColouriseErrorListDoc(unsigned int startPos, int length, int, WordLi styler.StartAt(startPos); styler.StartSegment(startPos); unsigned int linePos = 0; - for (unsigned int i = startPos; i <= startPos + length; i++) { + for (unsigned int i = startPos; i < startPos + length; i++) { lineBuffer[linePos++] = styler[i]; if (styler[i] == '\r' || styler[i] == '\n' || (linePos >= sizeof(lineBuffer) - 1)) { ColouriseErrorListLine(lineBuffer, linePos, i, styler); |