3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-24 17:45:32 +00:00
This commit is contained in:
Jakob Rath 2022-11-30 15:24:35 +01:00
parent a8ecfd1313
commit ea9e5a47c7

View file

@ -1678,7 +1678,7 @@ namespace dd {
unsigned pow;
if (val.is_power_of_two(pow) && pow > 10)
return out << "2^" << pow;
else if ((val + 1).is_power_of_two(pow) && pow > 10) {
else if (val < m.max_value() && (val + 1).is_power_of_two(pow) && pow > 10) {
if (require_parens)
out << "(";
out << "2^" << pow << "-1";