Ignore warnings for yulOptimizer tests

This commit is contained in:
Harikrishnan Mulackal
2020-06-09 13:03:57 +02:00
committed by chriseth
parent 73e634924e
commit d8263d331e
12 changed files with 67 additions and 44 deletions
+2 -2
View File
@@ -87,12 +87,12 @@ pair<shared_ptr<Block>, shared_ptr<yul::AsmAnalysisInfo>> yul::test::parse(
shared_ptr<Object> parserResult = yul::ObjectParser(errorReporter, _dialect).parse(scanner, false);
if (!parserResult)
return {};
if (!parserResult->code || !errorReporter.errors().empty())
if (!parserResult->code || errorReporter.hasErrors())
return {};
shared_ptr<AsmAnalysisInfo> analysisInfo = make_shared<AsmAnalysisInfo>();
AsmAnalyzer analyzer(*analysisInfo, errorReporter, _dialect, {}, parserResult->dataNames());
// TODO this should be done recursively.
if (!analyzer.analyze(*parserResult->code) || !errorReporter.errors().empty())
if (!analyzer.analyze(*parserResult->code) || errorReporter.hasErrors())
return {};
return {std::move(parserResult->code), std::move(analysisInfo)};
}