mirror of
https://github.com/Z3Prover/z3
synced 2026-02-22 08:17:37 +00:00
Fix Priority 1 ASSERT_FAIL bugs - replace assertions with proper error handling
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
parent
ac19bdb9a7
commit
ae328dc006
4 changed files with 43 additions and 25 deletions
|
|
@ -78,7 +78,8 @@ def ehash(v):
|
|||
|
||||
"""
|
||||
if z3_debug():
|
||||
assert is_expr(v)
|
||||
if not is_expr(v):
|
||||
raise ValueError(f"ehash expects a Z3 expression, got {type(v)}")
|
||||
|
||||
return "{}_{}_{}".format(str(v), v.hash(), v.sort_kind())
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue