diff --git a/lib/checkother.cpp b/lib/checkother.cpp index c82a96023..aa14c5a51 100644 --- a/lib/checkother.cpp +++ b/lib/checkother.cpp @@ -565,8 +565,6 @@ static void eraseNotLocalArg(std::map& container, co const Variable* var = symbolDatabase->getVariableFromVarId(i->first); if (!var || nonLocal(var)) { container.erase(i++); - if (i == container.end()) - break; } else ++i; }