From 96229bb5f01e86efe382523e1ee79ff23bdcc8e0 Mon Sep 17 00:00:00 2001 From: Joe Mueller Date: Thu, 30 Jul 2015 14:35:17 +1000 Subject: Use Sci_Position / Sci_PositionU for variables in lexers that represent positions and line numbers and may be widened to 64-bits in a future release. --- lexers/LexMagik.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'lexers/LexMagik.cxx') diff --git a/lexers/LexMagik.cxx b/lexers/LexMagik.cxx index 02d457d55..4a2a7b9fb 100644 --- a/lexers/LexMagik.cxx +++ b/lexers/LexMagik.cxx @@ -141,7 +141,7 @@ static void ColouriseMagikDoc(Sci_PositionU startPos, Sci_Position length, int i char keywordChar = static_cast( tolower(styler.SafeGetCharAt( scanPosition + - static_cast(sc.currentPos+1), ' '))); + static_cast(sc.currentPos+1), ' '))); if(IsAlpha(keywordChar)) { keyword[scanPosition] = keywordChar; } else { @@ -365,18 +365,18 @@ static void FoldMagikDoc(Sci_PositionU startPos, Sci_Position length, int, bool compact = styler.GetPropertyInt("fold.compact") != 0; WordList &foldingElements = *keywordslists[5]; - int endPos = startPos + length; - int line = styler.GetLine(startPos); + Sci_Position endPos = startPos + length; + Sci_Position line = styler.GetLine(startPos); int level = styler.LevelAt(line) & SC_FOLDLEVELNUMBERMASK; int flags = styler.LevelAt(line) & ~SC_FOLDLEVELNUMBERMASK; for( - int currentPos = startPos; + Sci_Position currentPos = startPos; currentPos < endPos; currentPos++) { char currentState = styler.StyleAt(currentPos); char c = styler.SafeGetCharAt(currentPos, ' '); - int prevLine = styler.GetLine(currentPos - 1); + Sci_Position prevLine = styler.GetLine(currentPos - 1); line = styler.GetLine(currentPos); // Default situation -- cgit v1.2.3