diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2018-05-09 17:43:14 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2018-05-09 18:28:49 +0800 |
commit | 591c591af05f29bf42b8b162a4fcda5a9a8fae9f (patch) | |
tree | a448d572df111ba938bbca43098864852507236a /libjulia/optimiser/DataFlowAnalyzer.cpp | |
parent | 7bbfd77e8e924f4946fcc99d4334d7e8ad3cc8de (diff) | |
download | dexon-solidity-591c591af05f29bf42b8b162a4fcda5a9a8fae9f.tar.gz dexon-solidity-591c591af05f29bf42b8b162a4fcda5a9a8fae9f.tar.zst dexon-solidity-591c591af05f29bf42b8b162a4fcda5a9a8fae9f.zip |
Do not use solAssert within libjulia
Diffstat (limited to 'libjulia/optimiser/DataFlowAnalyzer.cpp')
-rw-r--r-- | libjulia/optimiser/DataFlowAnalyzer.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libjulia/optimiser/DataFlowAnalyzer.cpp b/libjulia/optimiser/DataFlowAnalyzer.cpp index 56653393..25f0ffb4 100644 --- a/libjulia/optimiser/DataFlowAnalyzer.cpp +++ b/libjulia/optimiser/DataFlowAnalyzer.cpp @@ -23,11 +23,11 @@ #include <libjulia/optimiser/DataFlowAnalyzer.h> #include <libjulia/optimiser/NameCollector.h> +#include <libjulia/optimiser/Semantics.h> +#include <libjulia/Exceptions.h> #include <libsolidity/inlineasm/AsmData.h> -#include <libjulia/optimiser/Semantics.h> - #include <libdevcore/CommonData.h> #include <boost/range/adaptor/reversed.hpp> @@ -41,7 +41,7 @@ void DataFlowAnalyzer::operator()(Assignment& _assignment) set<string> names; for (auto const& var: _assignment.variableNames) names.insert(var.name); - solAssert(_assignment.value, ""); + assertThrow(_assignment.value, OptimizerException, ""); visit(*_assignment.value); handleAssignment(names, _assignment.value.get()); } @@ -120,7 +120,7 @@ void DataFlowAnalyzer::operator()(Block& _block) m_variableScopes.emplace_back(false); ASTModifier::operator()(_block); m_variableScopes.pop_back(); - solAssert(numScopes == m_variableScopes.size(), ""); + assertThrow(numScopes == m_variableScopes.size(), OptimizerException, ""); } void DataFlowAnalyzer::handleAssignment(set<string> const& _variables, Expression* _value) |