diff options
author | Leonardo Alt <leo@ethereum.org> | 2018-11-26 18:55:53 +0800 |
---|---|---|
committer | Leonardo Alt <leo@ethereum.org> | 2018-11-26 19:54:02 +0800 |
commit | aaaa92012cdab9c11984dfab2d0d56a1c537a61e (patch) | |
tree | 313afc37f1b5e069b834160523fb57cf40dae2ee /libsolidity | |
parent | 0b474d52994028392402ca1e7f56b613ab365dec (diff) | |
download | dexon-solidity-aaaa92012cdab9c11984dfab2d0d56a1c537a61e.tar.gz dexon-solidity-aaaa92012cdab9c11984dfab2d0d56a1c537a61e.tar.zst dexon-solidity-aaaa92012cdab9c11984dfab2d0d56a1c537a61e.zip |
[SMTChecker] Unknown answer for constant condition check should not do anything
Diffstat (limited to 'libsolidity')
-rw-r--r-- | libsolidity/formal/SMTChecker.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libsolidity/formal/SMTChecker.cpp b/libsolidity/formal/SMTChecker.cpp index 5b7807f7..477568a0 100644 --- a/libsolidity/formal/SMTChecker.cpp +++ b/libsolidity/formal/SMTChecker.cpp @@ -889,6 +889,10 @@ void SMTChecker::checkBooleanNotConstant(Expression const& _condition, string co { // everything fine. } + else if (positiveResult == smt::CheckResult::UNKNOWN || negatedResult == smt::CheckResult::UNKNOWN) + { + // can't do anything. + } else if (positiveResult == smt::CheckResult::UNSATISFIABLE && negatedResult == smt::CheckResult::UNSATISFIABLE) m_errorReporter.warning(_condition.location(), "Condition unreachable."); else |