diff options
author | Leonardo Alt <leonardoaltt@gmail.com> | 2018-01-21 20:58:56 +0800 |
---|---|---|
committer | Leonardo Alt <leonardoaltt@gmail.com> | 2018-03-13 03:16:47 +0800 |
commit | 6a940f0a99e941c48e5deb695e89ac52784c4f3c (patch) | |
tree | 547d592bca858c48dbdce61aafb2b71ac7369338 /libsolidity/formal/SSAVariable.cpp | |
parent | 886dc0512cba2c6bd6198eca88f1e84c55d392e5 (diff) | |
download | dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar.gz dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar.bz2 dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar.lz dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar.xz dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.tar.zst dexon-solidity-6a940f0a99e941c48e5deb695e89ac52784c4f3c.zip |
[SMTChecker] Support to Bool variables
Diffstat (limited to 'libsolidity/formal/SSAVariable.cpp')
-rw-r--r-- | libsolidity/formal/SSAVariable.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libsolidity/formal/SSAVariable.cpp b/libsolidity/formal/SSAVariable.cpp index 4e6bcbcb..4f8080ab 100644 --- a/libsolidity/formal/SSAVariable.cpp +++ b/libsolidity/formal/SSAVariable.cpp @@ -17,6 +17,7 @@ #include <libsolidity/formal/SSAVariable.h> +#include <libsolidity/formal/SymbolicBoolVariable.h> #include <libsolidity/formal/SymbolicIntVariable.h> #include <libsolidity/ast/AST.h> @@ -34,6 +35,8 @@ SSAVariable::SSAVariable( if (dynamic_cast<IntegerType const*>(_decl->type().get())) m_symbolicVar = make_shared<SymbolicIntVariable>(_decl, _interface); + else if (dynamic_cast<BoolType const*>(_decl->type().get())) + m_symbolicVar = make_shared<SymbolicBoolVariable>(_decl, _interface); else { solAssert(false, ""); @@ -42,7 +45,8 @@ SSAVariable::SSAVariable( bool SSAVariable::supportedType(Type const* _decl) { - return dynamic_cast<IntegerType const*>(_decl); + return dynamic_cast<IntegerType const*>(_decl) || + dynamic_cast<BoolType const*>(_decl); } void SSAVariable::resetIndex() |