summaryrefslogtreecommitdiff
path: root/src/printer/smt2/smt2_printer.cpp
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2019-12-16 11:56:39 -0600
committerAndres Noetzli <andres.noetzli@gmail.com>2019-12-16 09:56:39 -0800
commitc101a6b42d1f14bc750fb2328ddd83261148d7ae (patch)
tree3155d3edd7c26690088cbc9a223de5c854941475 /src/printer/smt2/smt2_printer.cpp
parentd15d44b3c91b5be2c19adac292f137d2a67eb848 (diff)
Move Datatype management to ExprManager (#3568)
This is further work towards decoupling the Expr layer from the Node layer. This commit makes it so that ExprManager does memory management for Datatype while NodeManager maintains a list of DType. As a reminder, the ownership policy (and level of indirection through DatatypeIndex) is necessary due to not being able to store Datatype within Node since this leads to circular dependencies in the Node AST.
Diffstat (limited to 'src/printer/smt2/smt2_printer.cpp')
-rw-r--r--src/printer/smt2/smt2_printer.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/printer/smt2/smt2_printer.cpp b/src/printer/smt2/smt2_printer.cpp
index 006895df7..f0a1e740f 100644
--- a/src/printer/smt2/smt2_printer.cpp
+++ b/src/printer/smt2/smt2_printer.cpp
@@ -21,6 +21,7 @@
#include <typeinfo>
#include <vector>
+#include "expr/dtype.h"
#include "expr/node_manager_attributes.h"
#include "options/bv_options.h"
#include "options/language.h"
@@ -246,7 +247,7 @@ void Smt2Printer::toStream(std::ostream& out,
case kind::DATATYPE_TYPE:
{
- const Datatype& dt = (NodeManager::currentNM()->getDatatypeForIndex(
+ const DType& dt = (NodeManager::currentNM()->getDTypeForIndex(
n.getConst<DatatypeIndexConstant>().getIndex()));
if (dt.isTuple())
{
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback