diff options
author | nyamatongwe <unknown> | 2010-05-11 03:38:48 +0000 |
---|---|---|
committer | nyamatongwe <unknown> | 2010-05-11 03:38:48 +0000 |
commit | cbb322ab4639975a0326c455da89e73f0bbb0785 (patch) | |
tree | dd74d3082fddf055535c0576e4be7aa272123637 | |
parent | 8a6ef2beb841be1bb169d18fab79fc718e9b37ca (diff) | |
download | scintilla-mirror-cbb322ab4639975a0326c455da89e73f0bbb0785.tar.gz |
Removed redundant code.
-rw-r--r-- | src/ExternalLexer.cxx | 6 | ||||
-rw-r--r-- | src/LexHTML.cxx | 8 |
2 files changed, 5 insertions, 9 deletions
diff --git a/src/ExternalLexer.cxx b/src/ExternalLexer.cxx index a0e58185c..9e175a88f 100644 --- a/src/ExternalLexer.cxx +++ b/src/ExternalLexer.cxx @@ -202,10 +202,8 @@ LexerManager *LexerManager::GetInstance() { /// Delete any LexerManager instance... void LexerManager::DeleteInstance() { - if (theInstance) { - delete theInstance; - theInstance = NULL; - } + delete theInstance; + theInstance = NULL; } /// protected constructor - this is a singleton... diff --git a/src/LexHTML.cxx b/src/LexHTML.cxx index fe80adf8a..a3d883ab8 100644 --- a/src/LexHTML.cxx +++ b/src/LexHTML.cxx @@ -587,8 +587,6 @@ static void ColouriseHyperTextDoc(unsigned int startPos, int length, int initSty styler.StartAt(startPos, static_cast<char>(STYLE_MAX)); char prevWord[200]; prevWord[0] = '\0'; - char nextWord[200]; - nextWord[0] = '\0'; char phpStringDelimiter[200]; // PHP is not limited in length, we are phpStringDelimiter[0] = '\0'; int StateToPrint = initStyle; @@ -683,7 +681,7 @@ static void ColouriseHyperTextDoc(unsigned int startPos, int length, int initSty const bool isMako = styler.GetPropertyInt("lexer.html.mako", 0) != 0; // property lexer.html.django - // Set to 1 to enable the django template language. + // Set to 1 to enable the django template language. const bool isDjango = styler.GetPropertyInt("lexer.html.django", 0) != 0; const CharacterSet setHTMLWord(CharacterSet::setAlphaNum, ".-_:!#", 0x80, true); @@ -1074,8 +1072,8 @@ static void ColouriseHyperTextDoc(unsigned int startPos, int length, int initSty } // handle the end of Django template code - else if (isDjango && - ((inScriptType == eNonHtmlPreProc) || (inScriptType == eNonHtmlScriptPreProc)) && + else if (isDjango && + ((inScriptType == eNonHtmlPreProc) || (inScriptType == eNonHtmlScriptPreProc)) && (scriptLanguage != eScriptNone) && stateAllowsTermination(state) && isDjangoBlockEnd(ch, chNext, djangoBlockType)) { if (state == SCE_H_ASPAT) { |