diff --git a/lib/checkassert.cpp b/lib/checkassert.cpp index 25d4a94bf..45beda62b 100644 --- a/lib/checkassert.cpp +++ b/lib/checkassert.cpp @@ -81,7 +81,7 @@ void CheckAssert::assertWithSideEffects() bool noReturnInScope = true; for (std::vector::iterator rt = returnTokens.begin(); rt != returnTokens.end(); ++rt) { - if (!inSameScope(*rt, tok2)) { + if (inSameScope(*rt, tok2)) { noReturnInScope = false; break; }