parent
e1a97c524d
commit
4f1e8bc5e7
|
@ -632,7 +632,7 @@ void CheckCondition::multiCondition2()
|
|||
[&varsInCond](const Token *cond) {
|
||||
if (cond->variable()) {
|
||||
const Variable *var = cond->variable();
|
||||
if(std::find(varsInCond.begin(), varsInCond.end(), var) == varsInCond.end())
|
||||
if (std::find(varsInCond.begin(), varsInCond.end(), var) == varsInCond.end())
|
||||
varsInCond.push_back(var);
|
||||
}
|
||||
return ChildrenToVisit::op1_and_op2;
|
||||
|
|
|
@ -1299,7 +1299,7 @@ static bool isVariableMutableInInitializer(const Token* start, const Token * end
|
|||
const Token * memberTok = tok->astParent()->previous();
|
||||
if (Token::Match(memberTok, "%var% (") && memberTok->variable()) {
|
||||
const Variable * memberVar = memberTok->variable();
|
||||
if(memberVar->isClass())
|
||||
if (memberVar->isClass())
|
||||
//TODO: check if the called constructor could live with a const variable
|
||||
// pending that, assume the worst (that it can't)
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue