diff --git a/src/tokenize.cpp b/src/tokenize.cpp index 2e5b5ae12..cbb023fb6 100644 --- a/src/tokenize.cpp +++ b/src/tokenize.cpp @@ -2746,9 +2746,8 @@ void Tokenizer::simplifyIfNot() } -bool Tokenizer::simplifyIfNotNull() +void Tokenizer::simplifyIfNotNull() { - bool ret = false; for (Token *tok = _tokens; tok; tok = tok->next()) { Token *deleteFrom = NULL; @@ -2784,11 +2783,8 @@ bool Tokenizer::simplifyIfNotNull() { Token::eraseTokens(deleteFrom, deleteFrom->tokAt(3)); tok = deleteFrom; - ret = true; } - } - return ret; } diff --git a/src/tokenize.h b/src/tokenize.h index ece7edbaf..921c529b9 100644 --- a/src/tokenize.h +++ b/src/tokenize.h @@ -150,10 +150,8 @@ private: /** * simplify if-not NULL.. * Example: "if(0!=x);" => "if(x);" - * @return true if something is modified - * false if nothing is done. */ - bool simplifyIfNotNull(); + void simplifyIfNotNull(); /** * Simplify the "not" and "and" keywords to "!" and "&&"