aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexers/LexCPP.cxx
diff options
context:
space:
mode:
authorhuki <gk7huki@gmail.com>2018-09-24 09:24:10 +1000
committerhuki <gk7huki@gmail.com>2018-09-24 09:24:10 +1000
commite95830ea8681727d86665d06dd1689019a01a335 (patch)
treeb164767014570781d6de2982a0a1f6a54ace74f4 /lexers/LexCPP.cxx
parentbfac5d65c34a5a4965f2fe21cf1ebd4c39811f2a (diff)
downloadscintilla-mirror-e95830ea8681727d86665d06dd1689019a01a335.tar.gz
Backport: Bug [#2045]. LexCPP: Fix 'elif' token length
Backport of changeset 7094:fa4b41e8a452.
Diffstat (limited to 'lexers/LexCPP.cxx')
-rw-r--r--lexers/LexCPP.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/lexers/LexCPP.cxx b/lexers/LexCPP.cxx
index a3942b5e3..3dac142ab 100644
--- a/lexers/LexCPP.cxx
+++ b/lexers/LexCPP.cxx
@@ -1279,7 +1279,7 @@ void SCI_METHOD LexerCPP::Lex(Sci_PositionU startPos, Sci_Position length, int i
// Ensure only one chosen out of #if .. #elif .. #elif .. #else .. #endif
if (!preproc.CurrentIfTaken()) {
// Similar to #if
- std::string restOfLine = GetRestOfLine(styler, sc.currentPos + 2, true);
+ std::string restOfLine = GetRestOfLine(styler, sc.currentPos + 4, true);
const bool ifGood = EvaluateExpression(restOfLine, preprocessorDefinitions);
if (ifGood) {
preproc.InvertCurrentLevel();