From 58471e908a3b74b27379bb19a13d62cd8d4476b0 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/LexASY.cxx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'lexers/LexASY.cxx') diff --git a/lexers/LexASY.cxx b/lexers/LexASY.cxx index 722eb2dfa..b49975e70 100644 --- a/lexers/LexASY.cxx +++ b/lexers/LexASY.cxx @@ -152,7 +152,7 @@ static inline bool isASYidentifier(int ch) { ((ch >= 'a') && (ch <= 'z')) || ((ch >= 'A') && (ch <= 'Z')) ; } -static int ParseASYWord(unsigned int pos, Accessor &styler, char *word) +static int ParseASYWord(Sci_PositionU pos, Accessor &styler, char *word) { int length=0; char ch=styler.SafeGetCharAt(pos); @@ -167,11 +167,11 @@ static int ParseASYWord(unsigned int pos, Accessor &styler, char *word) return length; } -static bool IsASYDrawingLine(int line, Accessor &styler) { - int pos = styler.LineStart(line); - int eol_pos = styler.LineStart(line + 1) - 1; +static bool IsASYDrawingLine(Sci_Position line, Accessor &styler) { + Sci_Position pos = styler.LineStart(line); + Sci_Position eol_pos = styler.LineStart(line + 1) - 1; - int startpos = pos; + Sci_Position startpos = pos; char buffer[100]=""; while (startpos 0) levelCurrent = styler.LevelAt(lineCurrent-1) >> 16; @@ -202,7 +202,7 @@ static void FoldAsyDoc(Sci_PositionU startPos, Sci_Position length, int initStyl char chNext = styler[startPos]; int styleNext = styler.StyleAt(startPos); int style = initStyle; - for (unsigned int i = startPos; i < endPos; i++) { + for (Sci_PositionU i = startPos; i < endPos; i++) { char ch = chNext; chNext = styler.SafeGetCharAt(i + 1); int stylePrev = style; -- cgit v1.2.3