Merge pull request #416 from Dmitry-Me/removeDuplicateChecks
Remove duplicate checks
This commit is contained in:
commit
5d0aa15002
|
@ -1306,9 +1306,9 @@ static void valueFlowForLoopSimplify(Token * const bodyStart, const unsigned int
|
||||||
while (parent) {
|
while (parent) {
|
||||||
const Token * const p = parent;
|
const Token * const p = parent;
|
||||||
parent = parent->astParent();
|
parent = parent->astParent();
|
||||||
if (parent && parent->str() == ":")
|
if (!parent || parent->str() == ":")
|
||||||
break;
|
break;
|
||||||
if (parent && parent->str() == "?") {
|
if (parent->str() == "?") {
|
||||||
if (parent->astOperand2() != p)
|
if (parent->astOperand2() != p)
|
||||||
parent = NULL;
|
parent = NULL;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue