mirror of
https://github.com/Z3Prover/z3
synced 2025-06-07 14:43:23 +00:00
expose propagate created
This commit is contained in:
parent
e1ffaa7faf
commit
8ca023d541
12 changed files with 67 additions and 33 deletions
|
@ -964,4 +964,23 @@ extern "C" {
|
|||
Z3_CATCH;
|
||||
}
|
||||
|
||||
void Z3_API Z3_solver_propagate_created(Z3_context c, Z3_solver s, Z3_created_eh created_eh) {
|
||||
Z3_TRY;
|
||||
RESET_ERROR_CODE();
|
||||
user_propagator::register_created_eh_t c = (void(*)(void*, user_propagator::callback*, expr*, unsigned))created_eh;
|
||||
to_solver_ref(s)->user_propagate_register_created(c);
|
||||
Z3_CATCH;
|
||||
}
|
||||
|
||||
Z3_func_decl Z3_API Z3_solver_propagate_declare(Z3_context c, Z3_solver s, Z3_symbol name, unsigned n, Z3_sort* domain, Z3_sort range) {
|
||||
Z3_TRY;
|
||||
LOG_Z3_solver_propagate_declare(c, s, name, n, domain, range);
|
||||
RESET_ERROR_CODE();
|
||||
func_decl* f = to_solver_ref(s)->user_propagate_declare(to_symbol(name), n, to_sorts(domain), to_sort(range));
|
||||
mk_c(c)->save_ast_trail(f);
|
||||
RETURN_Z3(of_func_decl(f));
|
||||
Z3_CATCH_RETURN(nullptr);
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue