mirror of
https://github.com/Z3Prover/z3
synced 2025-05-10 17:25:47 +00:00
update namespace, hoist exported functions outside of embedded namespace
This commit is contained in:
parent
644118660f
commit
a51239c641
4 changed files with 32 additions and 36 deletions
|
@ -60,7 +60,7 @@ Revision History:
|
||||||
|
|
||||||
#define IS_CGR_SUPPORT true
|
#define IS_CGR_SUPPORT true
|
||||||
|
|
||||||
namespace q {
|
namespace euf {
|
||||||
// ------------------------------------
|
// ------------------------------------
|
||||||
//
|
//
|
||||||
// Trail
|
// Trail
|
||||||
|
@ -3885,7 +3885,11 @@ namespace q {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
void mam::ground_subterms(expr* e, ptr_vector<app>& ground) {
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void euf::mam::ground_subterms(expr* e, ptr_vector<app>& ground) {
|
||||||
ground.reset();
|
ground.reset();
|
||||||
expr_fast_mark1 mark;
|
expr_fast_mark1 mark;
|
||||||
ptr_buffer<app> todo;
|
ptr_buffer<app> todo;
|
||||||
|
@ -3907,9 +3911,6 @@ namespace q {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mam* mam::mk(euf::mam_solver& ctx, euf::on_binding_callback& em) {
|
euf::mam* euf::mam::mk(euf::mam_solver& ctx, euf::on_binding_callback& em) {
|
||||||
return alloc(mam_impl, ctx, em, true);
|
return alloc(mam_impl, ctx, em, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
@ -39,16 +39,11 @@ namespace euf {
|
||||||
virtual ~on_binding_callback() = default;
|
virtual ~on_binding_callback() = default;
|
||||||
virtual void on_binding(quantifier* q, app* pat, euf::enode* const* binding, unsigned max_generation, unsigned min_gen, unsigned max_gen) = 0;
|
virtual void on_binding(quantifier* q, app* pat, euf::enode* const* binding, unsigned max_generation, unsigned min_gen, unsigned max_gen) = 0;
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
namespace q {
|
|
||||||
|
|
||||||
typedef euf::enode enode;
|
typedef euf::enode enode;
|
||||||
typedef euf::egraph egraph;
|
typedef euf::egraph egraph;
|
||||||
typedef euf::enode_vector enode_vector;
|
typedef euf::enode_vector enode_vector;
|
||||||
|
|
||||||
class ematch;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
\brief Matching Abstract Machine (MAM)
|
\brief Matching Abstract Machine (MAM)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -76,7 +76,7 @@ namespace q {
|
||||||
if (!ctx.relevancy_enabled())
|
if (!ctx.relevancy_enabled())
|
||||||
ctx.get_egraph().set_on_make(_on_make);
|
ctx.get_egraph().set_on_make(_on_make);
|
||||||
}
|
}
|
||||||
m_mam = mam::mk(ctx, *this);
|
m_mam = euf::mam::mk(ctx, *this);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ematch::relevant_eh(euf::enode* n) {
|
void ematch::relevant_eh(euf::enode* n) {
|
||||||
|
@ -85,7 +85,7 @@ namespace q {
|
||||||
}
|
}
|
||||||
|
|
||||||
void ematch::ensure_ground_enodes(expr* e) {
|
void ematch::ensure_ground_enodes(expr* e) {
|
||||||
mam::ground_subterms(e, m_ground);
|
euf::mam::ground_subterms(e, m_ground);
|
||||||
for (expr* g : m_ground)
|
for (expr* g : m_ground)
|
||||||
m_qs.e_internalize(g);
|
m_qs.e_internalize(g);
|
||||||
}
|
}
|
||||||
|
@ -557,7 +557,7 @@ namespace q {
|
||||||
* Attach ground subterms of patterns so they appear shared.
|
* Attach ground subterms of patterns so they appear shared.
|
||||||
*/
|
*/
|
||||||
void ematch::attach_ground_pattern_terms(expr* pat) {
|
void ematch::attach_ground_pattern_terms(expr* pat) {
|
||||||
mam::ground_subterms(pat, m_ground);
|
euf::mam::ground_subterms(pat, m_ground);
|
||||||
for (expr* g : m_ground) {
|
for (expr* g : m_ground) {
|
||||||
euf::enode* n = ctx.get_egraph().find(g);
|
euf::enode* n = ctx.get_egraph().find(g);
|
||||||
if (!n->is_attached_to(m_qs.get_id()))
|
if (!n->is_attached_to(m_qs.get_id()))
|
||||||
|
@ -602,7 +602,7 @@ namespace q {
|
||||||
if (!unary && j >= num_eager_multi_patterns) {
|
if (!unary && j >= num_eager_multi_patterns) {
|
||||||
TRACE("q", tout << "delaying (too many multipatterns):\n" << mk_ismt2_pp(mp, m) << "\n";);
|
TRACE("q", tout << "delaying (too many multipatterns):\n" << mk_ismt2_pp(mp, m) << "\n";);
|
||||||
if (!m_lazy_mam)
|
if (!m_lazy_mam)
|
||||||
m_lazy_mam = mam::mk(ctx, *this);
|
m_lazy_mam = euf::mam::mk(ctx, *this);
|
||||||
m_lazy_mam->add_pattern(q, mp);
|
m_lazy_mam->add_pattern(q, mp);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
@ -75,7 +75,7 @@ namespace q {
|
||||||
queue m_inst_queue;
|
queue m_inst_queue;
|
||||||
svector<prop> m_prop_queue;
|
svector<prop> m_prop_queue;
|
||||||
pattern_inference_rw m_infer_patterns;
|
pattern_inference_rw m_infer_patterns;
|
||||||
scoped_ptr<q::mam> m_mam, m_lazy_mam;
|
scoped_ptr<euf::mam> m_mam, m_lazy_mam;
|
||||||
ptr_vector<clause> m_clauses;
|
ptr_vector<clause> m_clauses;
|
||||||
obj_map<quantifier, unsigned> m_q2clauses;
|
obj_map<quantifier, unsigned> m_q2clauses;
|
||||||
vector<unsigned_vector> m_watch; // expr_id -> clause-index*
|
vector<unsigned_vector> m_watch; // expr_id -> clause-index*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue