Merge pull request #6027 from ethereum/failEnErrorListNonEmpty

Make analysis success not only dependent on flag but also on error list.
This commit is contained in:
chriseth 2019-02-20 15:19:48 +01:00 committed by GitHub
commit 00084a9bd7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,7 +52,10 @@ bool AsmAnalyzer::analyze(Block const& _block)
if (!(ScopeFiller(m_info, m_errorReporter))(_block))
return false;
return (*this)(_block);
bool success = (*this)(_block);
if (!success)
solAssert(m_errorReporter.hasErrors(), "No success but no error.");
return success && !m_errorReporter.hasErrors();
}
AsmAnalysisInfo AsmAnalyzer::analyzeStrictAssertCorrect(