diff --git a/lib/checkother.cpp b/lib/checkother.cpp index 81507e30c..3feb049e1 100644 --- a/lib/checkother.cpp +++ b/lib/checkother.cpp @@ -48,7 +48,7 @@ static bool astIsFloat(const Token *tok, bool unknown) if (!tok->variable()) return unknown; - return Token::findmatch(tok->variable()->typeStartToken(), "float|double", tok->variable()->typeEndToken()->next(), 0); + return Token::findmatch(tok->variable()->typeStartToken(), "float|double", tok->variable()->typeEndToken()->next(), 0) != nullptr; } return unknown; diff --git a/lib/token.cpp b/lib/token.cpp index 51becb2fb..c943c6192 100644 --- a/lib/token.cpp +++ b/lib/token.cpp @@ -1264,7 +1264,7 @@ std::string Token::astStringVerbose(const unsigned int indent1, const unsigned i void Token::printValueFlow() const { - int line = -1; + unsigned int line = 0; std::cout << "\n\n##Value flow" << std::endl; for (const Token *tok = this; tok; tok = tok->next()) { if (tok->values.empty())