mirror of
https://github.com/Z3Prover/z3
synced 2025-04-24 01:25:31 +00:00
fix model extraction for 0-ary recursive function declarations
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
e75d07c1c1
commit
d9e77ba443
1 changed files with 5 additions and 0 deletions
|
@ -4460,6 +4460,11 @@ namespace smt {
|
|||
auto& def = u.get_def(f);
|
||||
expr* rhs = def.get_rhs();
|
||||
if (!rhs) continue;
|
||||
if (f->get_arity() == 0) {
|
||||
m_model->register_decl(f, rhs);
|
||||
continue;
|
||||
}
|
||||
|
||||
func_interp* fi = alloc(func_interp, m, f->get_arity());
|
||||
// reverse argument order so that variable 0 starts at the beginning.
|
||||
expr_ref_vector subst(m);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue