mirror of
https://github.com/Z3Prover/z3
synced 2025-04-27 02:45:51 +00:00
Add support for initializing variable values in solver and optimize contexts in Z3
This commit is contained in:
parent
342dccdc02
commit
0c48a50d59
12 changed files with 98 additions and 9 deletions
|
@ -1008,7 +1008,8 @@ sort* basic_decl_plugin::join(unsigned n, expr* const* es) {
|
|||
}
|
||||
|
||||
sort* basic_decl_plugin::join(sort* s1, sort* s2) {
|
||||
if (s1 == s2) return s1;
|
||||
if (s1 == s2)
|
||||
return s1;
|
||||
if (s1->get_family_id() == arith_family_id &&
|
||||
s2->get_family_id() == arith_family_id) {
|
||||
if (s1->get_decl_kind() == REAL_SORT) {
|
||||
|
@ -1016,6 +1017,10 @@ sort* basic_decl_plugin::join(sort* s1, sort* s2) {
|
|||
}
|
||||
return s2;
|
||||
}
|
||||
if (s1 == m_bool_sort && s2->get_family_id() == arith_family_id)
|
||||
return s2;
|
||||
if (s2 == m_bool_sort && s1->get_family_id() == arith_family_id)
|
||||
return s1;
|
||||
std::ostringstream buffer;
|
||||
buffer << "Sorts " << mk_pp(s1, *m_manager) << " and " << mk_pp(s2, *m_manager) << " are incompatible";
|
||||
throw ast_exception(buffer.str());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue