mirror of
https://github.com/Z3Prover/z3
synced 2025-08-23 19:47:52 +00:00
One more case for ule_constraint::is_always_false
This commit is contained in:
parent
6218931dde
commit
8242069ba6
3 changed files with 6 additions and 2 deletions
|
@ -70,7 +70,7 @@ namespace {
|
|||
return;
|
||||
}
|
||||
// p <= -1 --> 0 <= 0
|
||||
if (rhs.is_val() && rhs.val() == rhs.manager().max_value()) {
|
||||
if (rhs.is_max()) {
|
||||
lhs = 0, rhs = 0;
|
||||
return;
|
||||
}
|
||||
|
@ -202,6 +202,8 @@ namespace polysat {
|
|||
return true; // 0 > ... is always false
|
||||
if (lhs == rhs)
|
||||
return true; // p > p
|
||||
if (rhs.is_max())
|
||||
return true; // p > -1
|
||||
if (lhs.is_one() && rhs.is_never_zero())
|
||||
return true; // 1 > p implies p == 0
|
||||
return lhs.is_val() && rhs.is_val() && lhs.val() <= rhs.val();
|
||||
|
|
|
@ -27,6 +27,7 @@ namespace polysat {
|
|||
|
||||
ule_constraint(constraint_manager& m, pdd const& l, pdd const& r);
|
||||
static void simplify(bool& is_positive, pdd& lhs, pdd& rhs);
|
||||
static bool is_always_false(bool is_positive, pdd const& lhs, pdd const& rhs);
|
||||
|
||||
public:
|
||||
~ule_constraint() override {}
|
||||
|
@ -35,7 +36,6 @@ namespace polysat {
|
|||
static std::ostream& display(std::ostream& out, lbool status, pdd const& lhs, pdd const& rhs);
|
||||
std::ostream& display(std::ostream& out, lbool status) const override;
|
||||
std::ostream& display(std::ostream& out) const override;
|
||||
static bool is_always_false(bool is_positive, pdd const& lhs, pdd const& rhs);
|
||||
bool is_always_false(bool is_positive) const override;
|
||||
bool is_currently_false(solver& s, bool is_positive) const override;
|
||||
bool is_currently_false(solver& s, assignment_t const& sub, bool is_positive) const override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue