summaryrefslogtreecommitdiff
path: root/src/theory/theory_model_builder.cpp
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2020-10-16 13:32:42 -0500
committerGitHub <noreply@github.com>2020-10-16 13:32:42 -0500
commit7c249b3efdeeb51fd3dfc2571bc529c55880cf5c (patch)
tree220a1c3f2aa53b047c2a52260fce3bd2dce22429 /src/theory/theory_model_builder.cpp
parent547df7cd146091674562dfa4812f10bae7765934 (diff)
Refactor SMT-level model object (#5277)
This refactors the SMT-level model object so that it is a wrapper around TheoryModel instead of a base class. This inheritance was unnecessary. Moreover, it removes the virtual base models of the SMT-level model which were based on Expr. Now the interface is more minimal and in terms of Node only. This PR further simplifies a few places in the code that interface with the SmtEngine with things related to models.
Diffstat (limited to 'src/theory/theory_model_builder.cpp')
-rw-r--r--src/theory/theory_model_builder.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/theory/theory_model_builder.cpp b/src/theory/theory_model_builder.cpp
index 0f69566d6..2f9e168c9 100644
--- a/src/theory/theory_model_builder.cpp
+++ b/src/theory/theory_model_builder.cpp
@@ -1082,7 +1082,7 @@ void TheoryEngineModelBuilder::computeAssignableInfo(
}
}
-void TheoryEngineModelBuilder::postProcessModel(bool incomplete, Model* m)
+void TheoryEngineModelBuilder::postProcessModel(bool incomplete, TheoryModel* m)
{
// if we are incomplete, there is no guarantee on the model.
// thus, we do not check the model here.
@@ -1090,12 +1090,11 @@ void TheoryEngineModelBuilder::postProcessModel(bool incomplete, Model* m)
{
return;
}
- TheoryModel* tm = static_cast<TheoryModel*>(m);
- Assert(tm != nullptr);
+ Assert(m != nullptr);
// debug-check the model if the checkModels() is enabled.
if (options::debugCheckModels())
{
- debugCheckModel(tm);
+ debugCheckModel(m);
}
}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback