3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-24 01:25:31 +00:00

remove template dependency for trail objects

This commit is contained in:
Nikolaj Bjorner 2021-03-19 11:14:20 -07:00
parent c05c5caab5
commit 15a7621e27
28 changed files with 46 additions and 58 deletions

View file

@ -716,7 +716,7 @@ namespace bv {
values[n->get_root_id()] = bv.mk_numeral(val, m_bits[v].size());
}
trail_stack<euf::solver>& solver::get_trail_stack() {
trail_stack& solver::get_trail_stack() {
return ctx.get_trail_stack();
}

View file

@ -359,7 +359,7 @@ namespace bv {
void merge_eh(theory_var, theory_var, theory_var v1, theory_var v2);
void after_merge_eh(theory_var r1, theory_var r2, theory_var v1, theory_var v2) { SASSERT(check_zero_one_bits(r1)); }
void unmerge_eh(theory_var v1, theory_var v2);
trail_stack<euf::solver>& get_trail_stack();
trail_stack& get_trail_stack();
// diagnostics
std::ostream& display(std::ostream& out, theory_var v) const;

View file

@ -42,7 +42,7 @@ namespace euf {
m(m),
si(si),
m_egraph(m),
m_trail(*this),
m_trail(),
m_rewriter(m),
m_unhandled_functions(m),
m_lookahead(nullptr),

View file

@ -73,7 +73,6 @@ namespace euf {
struct scope {
unsigned m_var_lim;
};
typedef trail_stack<solver> euf_trail_stack;
size_t* to_ptr(sat::literal l) { return TAG(size_t*, reinterpret_cast<size_t*>((size_t)(l.index() << 4)), 1); }
@ -93,7 +92,7 @@ namespace euf {
sat::sat_internalizer& si;
smt_params m_config;
euf::egraph m_egraph;
euf_trail_stack m_trail;
trail_stack m_trail;
stats m_stats;
th_rewriter m_rewriter;
func_decl_ref_vector m_unhandled_functions;
@ -265,7 +264,7 @@ namespace euf {
vec.push_back(val);
push(push_back_trail< V, false>(vec));
}
euf_trail_stack& get_trail_stack() { return m_trail; }
trail_stack& get_trail_stack() { return m_trail; }
void updt_params(params_ref const& p);
void set_lookahead(sat::lookahead* s) override { m_lookahead = s; }

View file

@ -71,8 +71,6 @@ namespace q {
class mam_impl;
typedef trail_stack<mam_impl> mam_trail_stack;
template<typename T>
class mam_value_trail : public value_trail<T> {

View file

@ -65,7 +65,7 @@ namespace euf {
return ctx.get_region();
}
trail_stack<euf::solver>& th_euf_solver::get_trail_stack() {
trail_stack& th_euf_solver::get_trail_stack() {
return ctx.get_trail_stack();
}

View file

@ -182,7 +182,7 @@ namespace euf {
sat::literal mk_literal(expr* e) const;
theory_var get_th_var(enode* n) const { return n->get_th_var(get_id()); }
theory_var get_th_var(expr* e) const;
trail_stack<euf::solver>& get_trail_stack();
trail_stack& get_trail_stack();
bool is_attached_to_var(enode* n) const;
bool is_root(theory_var v) const { return var2enode(v)->is_root(); }
void push() override { m_num_scopes++; }