Make Scintilla build properly with GCC/MinGW
Fix GCC compile error: extra qualification 'WordList::' on member 'SetWordAt' [-fpermissive] Fix GCC compile error: a storage class can only be specified for objects and functions Fix GCC compile error with invalid usage of conditional operator Invoke the "afterthought" part of the for loop in the normal code at the end of the loop where proper conditions can be used. Error message: third operand to the conditional operator is of type 'void', but the second operand is neither a throw-expression nor of type 'void' closes #1656 closes #1655
This commit is contained in:
parent
aa0bb73981
commit
6dab6621ba
@ -40,7 +40,7 @@
|
||||
#include "LexerModule.h"
|
||||
|
||||
// The following definitions are a copy of the ones in FindReplaceDlg.h
|
||||
static enum { searchHeaderLevel = SC_FOLDLEVELBASE + 1, fileHeaderLevel, resultLevel };
|
||||
enum { searchHeaderLevel = SC_FOLDLEVELBASE + 1, fileHeaderLevel, resultLevel };
|
||||
|
||||
|
||||
static inline bool AtEOL(Accessor &styler, unsigned int i) {
|
||||
|
@ -1654,7 +1654,7 @@ static void ColouriseUserDoc(unsigned int startPos, int length, int initStyle, W
|
||||
levelNext = levelCurrent;
|
||||
|
||||
StyleContext sc(startPos, length, initStyle, styler);
|
||||
for (; finished; dontMove?true:sc.Forward())
|
||||
for (; finished; )
|
||||
{
|
||||
dontMove = false;
|
||||
checkEOL = EOL_DEFAULT_VALUE;
|
||||
@ -1893,7 +1893,11 @@ static void ColouriseUserDoc(unsigned int startPos, int length, int initStyle, W
|
||||
{
|
||||
int length = iter->length();
|
||||
if (length == 0)
|
||||
{
|
||||
if (!dontMove)
|
||||
sc.Forward();
|
||||
continue;
|
||||
}
|
||||
|
||||
lineContinuation = true;
|
||||
for (int i=0; i<length; ++i)
|
||||
@ -2299,6 +2303,9 @@ static void ColouriseUserDoc(unsigned int startPos, int length, int initStyle, W
|
||||
isCommentLine = isInComment ? COMMENTLINE_YES:COMMENTLINE_NO;
|
||||
}
|
||||
}
|
||||
|
||||
if (!dontMove)
|
||||
sc.Forward();
|
||||
}
|
||||
sc.Complete();
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ public:
|
||||
bool InList(const char *s) const;
|
||||
bool InListAbbreviated(const char *s, const char marker) const;
|
||||
const char *WordAt(int n) const;
|
||||
void WordList::SetWordAt(int n, const char *word2Set) {
|
||||
void SetWordAt(int n, const char *word2Set) {
|
||||
words[n] = (char *)word2Set;
|
||||
};
|
||||
int StartAt(int n) const {
|
||||
|
Loading…
Reference in New Issue
Block a user