mirror of
https://github.com/Z3Prover/z3
synced 2025-10-12 10:40:17 +00:00
adding soft-assertions
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
e50e02e656
commit
552cbd840f
8 changed files with 30 additions and 5 deletions
|
@ -914,17 +914,26 @@ namespace sat {
|
|||
|
||||
for (unsigned i = 0; !inconsistent() && i < m_user_scope_literals.size(); ++i) {
|
||||
literal nlit = ~m_user_scope_literals[i];
|
||||
assign(nlit, justification());
|
||||
// propagate(false);
|
||||
assign(nlit, justification());
|
||||
}
|
||||
|
||||
for (unsigned i = 0; !inconsistent() && i < num_lits; ++i) {
|
||||
literal lit = lits[i];
|
||||
SASSERT(is_external((lit).var()));
|
||||
m_assumption_set.insert(lit);
|
||||
m_assumptions.push_back(lit);
|
||||
assign(lit, justification());
|
||||
// propagate(false);
|
||||
|
||||
if (m_config.soft_assumptions) {
|
||||
if (value(lit) == l_undef) {
|
||||
m_assumptions.push_back(lit);
|
||||
assign(lit, justification());
|
||||
}
|
||||
propagate(false);
|
||||
}
|
||||
else {
|
||||
m_assumptions.push_back(lit);
|
||||
assign(lit, justification());
|
||||
// propagate(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue