Ejemplo n.º 1
0
/**
   \brief Assert expressions from ctx into t.
*/
void assert_exprs_from(cmd_context const & ctx, assertion_set & t) {
    ptr_vector<expr>::const_iterator it  = ctx.begin_assertions();
    ptr_vector<expr>::const_iterator end = ctx.end_assertions();
    for (; it != end; ++it) {
        t.assert_expr(*it);
    }
}
Ejemplo n.º 2
0
 /**
    \brief Store in r the current set of assertions.
    r is (owned) by the external assertion set
 */
 void solver_exp::get_assertions(assertion_set & r) {
     SASSERT(&(r.m()) == &m_ext_mng);
     ast_translation translator(m, m_ext_mng, false);
     unsigned sz = m_assertions.size();
     for (unsigned i = 0; i < sz; i++) {
         expr * f = m_assertions.form(i);
         r.assert_expr(translator(f));
     }
 }
Ejemplo n.º 3
0
 br_status reduce_app(func_decl * f, unsigned num, expr * const * args, expr_ref & result, proof_ref & result_pr) {
     if (!m.is_term_ite(f))
         return BR_FAILED;
     expr_ref new_ite(m);
     new_ite = m.mk_app(f, num, args);
     
     expr_ref new_def(m);
     proof_ref new_def_pr(m);
     app_ref _result(m);
     if (m_defined_names.mk_name(new_ite, new_def, new_def_pr, _result, result_pr)) {
         m_set->assert_expr(new_def, new_def_pr);
         m_num_fresh++;
         if (m_produce_models) {
             if (!m_mc)
                 m_mc = alloc(filter_model_converter, m);
             m_mc->insert(_result->get_decl());
         }
     }
     result = _result.get();
     return BR_DONE;
 }