Closed rachitnigam closed 1 year ago
After digging in some more, I now realize that Context::declare
doesn't directly correspond to any SMTLIB form, while Context::declare_const
corresponds to the SMTLIB declare-const
. Since Context::declare
and Context::declare_const
are the same, as you pointed out, I think it makes sense to remove/deprecate Context::declare
and only keep Context::declare_const
.
Would you like to send a PR doing the above?
Thanks for filing this issue.
Sure, I can do that!
The
Context
has both adeclare
method, which dispatches todeclare_fun
, and adeclare_const
method, which uses the SMTLIBdeclare-const
construct. However,declare-const
in SMTLIB is defined to be a macro fordefine-fun
in the same way thatdeclare
is implemented (See Z3 reference). Because of this, we should probably only expose one of these methods on the context and deprecate the other.