diff options
author | Joe Mueller <devnull@localhost> | 2015-07-30 14:35:17 +1000 |
---|---|---|
committer | Joe Mueller <devnull@localhost> | 2015-07-30 14:35:17 +1000 |
commit | 96229bb5f01e86efe382523e1ee79ff23bdcc8e0 (patch) | |
tree | 5aa3c8becad92a397b02445001383e188070f287 /lexers/LexPB.cxx | |
parent | 7604a6b2a98fc2250408368eb51f8f6827d888c8 (diff) | |
download | scintilla-mirror-96229bb5f01e86efe382523e1ee79ff23bdcc8e0.tar.gz |
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.
Diffstat (limited to 'lexers/LexPB.cxx')
-rw-r--r-- | lexers/LexPB.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lexers/LexPB.cxx b/lexers/LexPB.cxx index 217154c27..df9689b3c 100644 --- a/lexers/LexPB.cxx +++ b/lexers/LexPB.cxx @@ -70,10 +70,10 @@ static inline bool IsAWordStart(const int ch) return (ch < 0x80) && (isalnum(ch) || ch == '_'); } -bool MatchUpperCase(Accessor &styler, int pos, const char *s) //Same as styler.Match() but uppercase comparison (a-z,A-Z and space only) +bool MatchUpperCase(Accessor &styler, Sci_Position pos, const char *s) //Same as styler.Match() but uppercase comparison (a-z,A-Z and space only) { char ch; - for (int i=0; *s; i++) + for (Sci_Position i=0; *s; i++) { ch=styler.SafeGetCharAt(pos+i); if (ch > 0x60) ch -= '\x20'; @@ -83,7 +83,7 @@ bool MatchUpperCase(Accessor &styler, int pos, const char *s) //Same as styler return true; } -static void ColourisePBDoc(Sci_PositionU startPos, Sci_Position length, int initStyle, WordList *keywordlists[], Accessor &styler) { +static void ColourisePBDoc(Sci_PositionU startPos, Sci_Position length, int initStyle,WordList *keywordlists[],Accessor &styler) { WordList &keywords = *keywordlists[0]; @@ -191,8 +191,8 @@ static void FoldPBDoc(Sci_PositionU startPos, Sci_Position length, int, WordList if( styler.GetPropertyInt("fold") == 0 ) return; - unsigned int endPos = startPos + length; - int lineCurrent = styler.GetLine(startPos); + Sci_PositionU endPos = startPos + length; + Sci_Position lineCurrent = styler.GetLine(startPos); int levelCurrent = SC_FOLDLEVELBASE; if (lineCurrent > 0) levelCurrent = styler.LevelAt(lineCurrent-1) >> 16; @@ -202,7 +202,7 @@ static void FoldPBDoc(Sci_PositionU startPos, Sci_Position length, int, WordList bool fNewLine=true; bool fMightBeMultiLineMacro=false; bool fBeginOfCommentFound=false; - for (unsigned int i = startPos; i < endPos; i++) + for (Sci_PositionU i = startPos; i < endPos; i++) { char ch = chNext; chNext = styler.SafeGetCharAt(i + 1); @@ -354,7 +354,7 @@ static void FoldPBDoc(Sci_PositionU startPos, Sci_Position length, int, WordList break; } } //switch (ch) - } //for (unsigned int i = startPos; i < endPos; i++) + } //for (Sci_PositionU i = startPos; i < endPos; i++) } static const char * const pbWordListDesc[] = { |