@@ -46,6 +46,7 @@ SyntaxTest::SyntaxTest(
46
46
m_minSeverity(_minSeverity)
47
47
{
48
48
m_optimiseYul = m_reader.boolSetting (" optimize-yul" , true );
49
+ m_viaIr = m_reader.boolSetting (" via-ir" , false );
49
50
}
50
51
51
52
void SyntaxTest::setupCompiler (CompilerStack& _compiler)
@@ -58,6 +59,7 @@ void SyntaxTest::setupCompiler(CompilerStack& _compiler)
58
59
OptimiserSettings::full () :
59
60
OptimiserSettings::minimal ()
60
61
);
62
+ _compiler.setViaIR (m_viaIr);
61
63
_compiler.setMetadataFormat (CompilerStack::MetadataFormat::NoMetadata);
62
64
_compiler.setMetadataHash (CompilerStack::MetadataHash::None);
63
65
}
@@ -67,13 +69,13 @@ void SyntaxTest::parseAndAnalyze()
67
69
try
68
70
{
69
71
runFramework (withPreamble (m_sources.sources ), PipelineStage::Compilation);
70
- if (!pipelineSuccessful () && stageSuccessful (PipelineStage::Analysis) && ! compiler (). isExperimentalAnalysis () )
72
+ if (!pipelineSuccessful () && stageSuccessful (PipelineStage::Analysis))
71
73
{
72
- ErrorList const & errors = compiler ().errors ();
73
- auto codeGeneretionErrorCount = count_if (errors.cbegin (), errors.cend (), [](auto const & error) {
74
+ ErrorList const & errors = compiler ().errors ();
75
+ auto codeGeneretionErrorCount = count_if (errors.cbegin (), errors.cend (), [](auto const & error) {
74
76
return error->type () == Error::Type::CodeGenerationError;
75
77
});
76
- auto errorCount = count_if (errors.cbegin (), errors.cend (), [](auto const & error) {
78
+ auto errorCount = count_if (errors.cbegin (), errors.cend (), [](auto const & error) {
77
79
return Error::isError (error->type ());
78
80
});
79
81
// failing compilation after successful analysis is a rare case,
0 commit comments