lib/tokenize: fix two compiler warnings about emtpy while loop

Fixes these warnings:
  lib/tokenize.cpp: In member function ‘bool Tokenizer::tokenize(std::istream&, const char*, const std::string&)’:
  lib/tokenize.cpp:1962: warning: suggest a space before ‘;’ or explicit braces around empty body in ‘while’ statement
  lib/tokenize.cpp: In member function ‘bool Tokenizer::tokenizeCondition(const std::string&)’:
  lib/tokenize.cpp:2174: warning: suggest a space before ‘;’ or explicit braces around empty body in ‘while’ statement

Signed-off-by: Stefan Naewe <stefan.naewe@googlemail.com>
This commit is contained in:
Stefan Naewe 2013-02-08 11:35:08 +01:00
parent 26ddf07366
commit 46fb31f9e5
1 changed files with 4 additions and 2 deletions

View File

@ -1959,7 +1959,8 @@ bool Tokenizer::tokenize(std::istream &code,
// Remove redundant parentheses
simplifyRedundantParentheses();
for (Token *tok = list.front(); tok; tok = tok->next())
while (TemplateSimplifier::simplifyNumericCalculations(tok));
while (TemplateSimplifier::simplifyNumericCalculations(tok))
;
// Handle templates..
simplifyTemplates();
@ -2171,7 +2172,8 @@ bool Tokenizer::tokenizeCondition(const std::string &code)
for (Token *tok = list.front();
tok;
tok = tok->next())
while (TemplateSimplifier::simplifyNumericCalculations(tok));
while (TemplateSimplifier::simplifyNumericCalculations(tok))
;
while (simplifyLogicalOperators()) { }