3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-05-11 09:44:43 +00:00

fix bug reported in issue #193: MBQI needs to avoid instantiating data-types that contain model values in nested positions

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-08-13 14:29:48 +02:00
parent 702af71a2d
commit cd838e5cf4
7 changed files with 100 additions and 40 deletions

View file

@ -68,17 +68,10 @@ namespace smt {
bool theory_opt::is_numeral(arith_util& a, expr* term) {
while (true) {
if (a.is_uminus(term) || a.is_to_real(term) || a.is_to_int(term)) {
term = to_app(term)->get_arg(0);
}
else if (a.is_numeral(term)) {
return true;
}
else {
return false;
}
while (a.is_uminus(term) || a.is_to_real(term) || a.is_to_int(term)) {
term = to_app(term)->get_arg(0);
}
return a.is_numeral(term);
}
};