diff --git a/src/ast/ast_smt_pp.cpp b/src/ast/ast_smt_pp.cpp index f40b8a554..bea669438 100644 --- a/src/ast/ast_smt_pp.cpp +++ b/src/ast/ast_smt_pp.cpp @@ -34,6 +34,7 @@ Revision History: #include "ast/for_each_ast.h" #include "ast/decl_collector.h" #include "math/polynomial/algebraic_numbers.h" +#include "ast/pp_params.hpp" // --------------------------------------- @@ -911,7 +912,9 @@ ast_smt_pp::ast_smt_pp(ast_manager& m): void ast_smt_pp::display_expr_smt2(std::ostream& strm, expr* n, unsigned indent, unsigned num_var_names, char const* const* var_names) { ptr_vector ql; smt_renaming rn; - smt_printer p(strm, m_manager, ql, rn, m_logic, false, m_simplify_implies, indent, num_var_names, var_names); + pp_params params; + bool no_lets = params.no_lets(); + smt_printer p(strm, m_manager, ql, rn, m_logic, no_lets, m_simplify_implies, indent, num_var_names, var_names); p(n); } diff --git a/src/ast/pp_params.pyg b/src/ast/pp_params.pyg index 6b43cbea3..c833b624a 100644 --- a/src/ast/pp_params.pyg +++ b/src/ast/pp_params.pyg @@ -6,6 +6,7 @@ def_module_params('pp', ('max_width', UINT, 80, 'max. width in pretty printer'), ('max_ribbon', UINT, 80, 'max. ribbon (width - indentation) in pretty printer'), ('max_depth', UINT, 5, 'max. term depth (when pretty printing SMT2 terms/formulas)'), + ('no_lets', BOOL, False, 'dont print lets in low level SMT printer'), ('min_alias_size', UINT, 10, 'min. size for creating an alias for a shared term (when pretty printing SMT2 terms/formulas)'), ('decimal', BOOL, False, 'pretty print real numbers using decimal notation (the output may be truncated). Z3 adds a ? if the value is not precise'), ('decimal_precision', UINT, 10, 'maximum number of decimal places to be used when pp.decimal=true'), diff --git a/src/ast/simplifiers/elim_unconstrained.h b/src/ast/simplifiers/elim_unconstrained.h index 0fdde5af2..5dced90d0 100644 --- a/src/ast/simplifiers/elim_unconstrained.h +++ b/src/ast/simplifiers/elim_unconstrained.h @@ -22,6 +22,8 @@ Author: class elim_unconstrained : public dependent_expr_simplifier { + friend class seq_simplifier; + struct node { unsigned m_refcount = 0; expr* m_term = nullptr; diff --git a/src/smt/smt_internalizer.cpp b/src/smt/smt_internalizer.cpp index 3a7b95e2c..68879b8ac 100644 --- a/src/smt/smt_internalizer.cpp +++ b/src/smt/smt_internalizer.cpp @@ -1536,7 +1536,7 @@ namespace smt { fml = mk_or(fmls); m_lemma_visitor.collect(fml); m_lemma_visitor.display_skolem_decls(std::cout); - m_lemma_visitor.display_assert(std::cout, fml.get(), true); + m_lemma_visitor.display_assert(std::cout, fml.get(), false); } }