diff options
author | Unknown <nyamatongwe@gmail.com> | 2013-09-10 16:38:11 +1000 |
---|---|---|
committer | Unknown <nyamatongwe@gmail.com> | 2013-09-10 16:38:11 +1000 |
commit | 399e79b90d077755af68dda07195068b151f5589 (patch) | |
tree | 627cb5f7246fe51e208d77f1526d09f5723de36f /lexlib/WordList.cxx | |
parent | 8dd25346bdaea0aa12ee83d35624d9d2c045af9a (diff) | |
download | scintilla-mirror-399e79b90d077755af68dda07195068b151f5589.tar.gz |
Cast away char subscripts to avoid warnings from clang.
Diffstat (limited to 'lexlib/WordList.cxx')
-rw-r--r-- | lexlib/WordList.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lexlib/WordList.cxx b/lexlib/WordList.cxx index eb91692d7..a325833d4 100644 --- a/lexlib/WordList.cxx +++ b/lexlib/WordList.cxx @@ -32,11 +32,11 @@ static char **ArrayFromWordList(char *wordlist, int *len, bool onlyLineEnds = fa for (int i=0; i<256; i++) { wordSeparator[i] = false; } - wordSeparator['\r'] = true; - wordSeparator['\n'] = true; + wordSeparator[static_cast<unsigned int>('\r')] = true; + wordSeparator[static_cast<unsigned int>('\n')] = true; if (!onlyLineEnds) { - wordSeparator[' '] = true; - wordSeparator['\t'] = true; + wordSeparator[static_cast<unsigned int>(' ')] = true; + wordSeparator[static_cast<unsigned int>('\t')] = true; } for (int j = 0; wordlist[j]; j++) { int curr = static_cast<unsigned char>(wordlist[j]); @@ -163,7 +163,7 @@ bool WordList::InList(const char *s) const { j++; } } - j = starts['^']; + j = starts[static_cast<unsigned int>('^')]; if (j >= 0) { while (words[j][0] == '^') { const char *a = words[j] + 1; @@ -215,7 +215,7 @@ bool WordList::InListAbbreviated(const char *s, const char marker) const { j++; } } - j = starts['^']; + j = starts[static_cast<unsigned int>('^')]; if (j >= 0) { while (words[j][0] == '^') { const char *a = words[j] + 1; |