diff options
author | Leonardo Alt <leo@ethereum.org> | 2018-04-20 22:56:10 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2018-07-27 23:15:34 +0800 |
commit | 87a38e1abe61547e66aedfa595a73fb78184d609 (patch) | |
tree | ba41f379fbf2713f2e885c0d641a5780a06d7fe4 /libsolidity/formal/SolverInterface.h | |
parent | 5faa60e8834b5302f8d58f719c6962ed3affb50f (diff) | |
download | dexon-solidity-87a38e1abe61547e66aedfa595a73fb78184d609.tar.gz dexon-solidity-87a38e1abe61547e66aedfa595a73fb78184d609.tar.zst dexon-solidity-87a38e1abe61547e66aedfa595a73fb78184d609.zip |
[SMTChecker] SMTPortfolio: use all SMT solvers available
Diffstat (limited to 'libsolidity/formal/SolverInterface.h')
-rw-r--r-- | libsolidity/formal/SolverInterface.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/libsolidity/formal/SolverInterface.h b/libsolidity/formal/SolverInterface.h index a6d65ce2..f8a2bebb 100644 --- a/libsolidity/formal/SolverInterface.h +++ b/libsolidity/formal/SolverInterface.h @@ -199,8 +199,10 @@ public: virtual void push() = 0; virtual void pop() = 0; - virtual Expression newFunction(std::string _name, Sort _domain, Sort _codomain) + virtual void declareFunction(std::string _name, Sort _domain, Sort _codomain) = 0; + Expression newFunction(std::string _name, Sort _domain, Sort _codomain) { + declareFunction(_name, _domain, _codomain); solAssert(_domain == Sort::Int, "Function sort not supported."); // Subclasses should do something here switch (_codomain) @@ -214,14 +216,18 @@ public: break; } } - virtual Expression newInteger(std::string _name) + virtual void declareInteger(std::string _name) = 0; + Expression newInteger(std::string _name) { // Subclasses should do something here + declareInteger(_name); return Expression(std::move(_name), {}, Sort::Int); } - virtual Expression newBool(std::string _name) + virtual void declareBool(std::string _name) = 0; + Expression newBool(std::string _name) { // Subclasses should do something here + declareBool(_name); return Expression(std::move(_name), {}, Sort::Bool); } |