[SMTChecker] Support tuple type declaration

This commit is contained in:
Leonardo Alt
2019-05-02 12:05:21 +02:00
parent 80f3bd2413
commit 6c7527ac90
13 changed files with 97 additions and 16 deletions
+18
View File
@@ -173,3 +173,21 @@ SymbolicEnumVariable::SymbolicEnumVariable(
{
solAssert(isEnum(m_type->category()), "");
}
SymbolicTupleVariable::SymbolicTupleVariable(
TypePointer _type,
string _uniqueName,
smt::SolverInterface& _interface
):
SymbolicVariable(move(_type), move(_uniqueName), _interface)
{
solAssert(isTuple(m_type->category()), "");
}
void SymbolicTupleVariable::setComponents(vector<shared_ptr<SymbolicVariable>> _components)
{
solAssert(m_components.empty(), "");
auto const& tupleType = dynamic_cast<TupleType const*>(m_type);
solAssert(_components.size() == tupleType->components().size(), "");
m_components = move(_components);
}