Example #1
0
 void context::display(std::ostream& out, b_justification j) const {
     switch (j.get_kind()) {
     case b_justification::AXIOM:
         out << "axiom";
         break;
     case b_justification::BIN_CLAUSE: {
         literal l2 = j.get_literal();
         out << "bin-clause ";
         display_literal(out, l2);
         break;
     }
     case b_justification::CLAUSE: {
         clause * cls = j.get_clause();
         out << "clause ";
         display_literals(out, cls->get_num_literals(), cls->begin_literals());
         break;
     }
     case b_justification::JUSTIFICATION:
         out << "justification";
         break;
     default:
         UNREACHABLE();
         break;
     }
     out << "\n";
 }
Example #2
0
 void context::display(std::ostream& out, b_justification j) const {
     switch (j.get_kind()) {
     case b_justification::AXIOM:
         out << "axiom";
         break;
     case b_justification::BIN_CLAUSE: {
         literal l2 = j.get_literal();
         out << "bin-clause ";
         display_literal(out, l2);
         break;
     }
     case b_justification::CLAUSE: {
         clause * cls = j.get_clause();
         out << "clause ";
         if (cls) out << literal_vector(cls->get_num_literals(), cls->begin());
         break;
     }
     case b_justification::JUSTIFICATION: {
         out << "justification " << j.get_justification()->get_from_theory() << ": ";
         literal_vector lits;
         const_cast<conflict_resolution&>(*m_conflict_resolution).justification2literals(j.get_justification(), lits);
         display_literals(out, lits);
         break;
     }
     default:
         UNREACHABLE();
         break;
     }
     out << "\n";
 }