Commit c4285c7d authored by Victor Yacovlev's avatar Victor Yacovlev

Added runtime error to out of alg lines when there is no any algorithm

parent ca197584
......@@ -1161,6 +1161,17 @@ void PDAutomataPrivate::setOutOfAlgError()
if (currentModule)
doNotEvaluate = currentModule->impl.algorhitms.size()>0;
bool hasAnyAlgorithmAfter = false;
for (int i=0; i<source.size(); i++) {
if (source[i]->type==LxPriAlgHeader) {
hasAnyAlgorithmAfter = true;
break;
}
}
if (!hasAnyAlgorithmAfter)
doNotEvaluate = false;
appendSimpleLine();
if (!currentContext.isEmpty() && currentContext.top())
currentContext.top()->last()->skipErrorEvaluation = doNotEvaluate;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment