PySMT 0.9.7.dev423__tar.gz → 0.9.7.dev426__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pysmt-0.9.7.dev423/PySMT.egg-info → pysmt-0.9.7.dev426}/PKG-INFO +1 -1
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426/PySMT.egg-info}/PKG-INFO +1 -1
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/__init__.py +1 -1
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/z3.py +8 -5
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_back.py +29 -3
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/LICENSE +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/MANIFEST.in +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/NOTICE +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/PySMT.egg-info/SOURCES.txt +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/PySMT.egg-info/dependency_links.txt +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/PySMT.egg-info/entry_points.txt +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/PySMT.egg-info/top_level.txt +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/README.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/CHANGES.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/api_ref.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/development.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/getting_started.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/index.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/tutorials/boolean_logic.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/docs/tutorials.rst +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/__main__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/check_version.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/install.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/base.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/bdd.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/btor.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/cvcfive.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/cvcfour.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/msat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/optimsat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/pico.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/yices.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/installers/z3.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/cmd/shell.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/configuration.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/constants.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/decorators.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/environment.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/exceptions.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/factory.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/fnode.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/formula.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/logics.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/operators.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/goal.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/msat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/optimizer.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/optimsat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/yices.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/optimization/z3.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/oracles.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/parsing.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/printers.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/rewritings.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/shortcuts.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/simplifier.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/annotations.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/commands.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/parser/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/parser/parser.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/printers.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/script.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/solver.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/smtlib/utils.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/bdd.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/btor.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/cvcfive.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/cvcfour.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/dynmsat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/eager.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/interpolation.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/msat.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/options.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/pico.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/portfolio.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/qelim.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/smtlib.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/solver.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/solvers/yices.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/substituter.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/configs/config1.ini +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/configs/config_bad.ini +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/examples.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/omt_examples.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/optimization_utils.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/parser_utils.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_annotations.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_fuzzed.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_generic_wrapper.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_griggio.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_model_validation.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_omt_lib_solver.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_examples.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_extensibility.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_lra.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_omt.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_arrays.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_lia.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_lira.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_lra.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_nia.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_nra.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_uf.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_qf_ufbv.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_parser_type_error.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/smtlib/test_smtlibscript.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_array.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_bdd.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_bv.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_bv_simplification.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_cnf.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_configuration.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_constants.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_cvc_quantifiers.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_dwf.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_eager_model.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_env.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_euf.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_formula.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_hr_parsing.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_imports.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_int.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_interpolation.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_lira.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_logics.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_models.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_native_qe.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_nia.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_nlira.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_optimization.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_optimizing.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_oracles.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_portfolio.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_printing.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_qe.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_regressions.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_rewritings.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_shannon_expansion.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_simplify.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_size.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_solving.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_sorts.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_string.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_typechecker.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_unsat_cores.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_walker_ext.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/test/test_walkers.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/type_checker.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/typing.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/utils.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/walkers/__init__.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/walkers/dag.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/walkers/generic.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/walkers/identitydag.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/pysmt/walkers/tree.py +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/setup.cfg +0 -0
- {pysmt-0.9.7.dev423 → pysmt-0.9.7.dev426}/setup.py +0 -0
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
from typing import Tuple, Union
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
VERSION: Union[Tuple[int, int, int], Tuple[int, int, int, str, int]] = (0, 9, 7, "dev",
|
|
22
|
+
VERSION: Union[Tuple[int, int, int], Tuple[int, int, int, str, int]] = (0, 9, 7, "dev", 426)
|
|
23
23
|
|
|
24
24
|
# Try to provide human-readable version of latest commit for dev versions
|
|
25
25
|
# E.g. v0.5.1-4-g49a49f2-wip
|
|
@@ -340,12 +340,12 @@ class Z3Converter(Converter, DagWalker):
|
|
|
340
340
|
z3.Z3_OP_IMPLIES: lambda args, expr: self.mgr.Implies(args[0], args[1]),
|
|
341
341
|
z3.Z3_OP_ITE: lambda args, expr: self.mgr.Ite(args[0], args[1], args[2]),
|
|
342
342
|
z3.Z3_OP_TO_REAL: lambda args, expr: self.mgr.ToReal(args[0]),
|
|
343
|
-
z3.Z3_OP_BAND : lambda args, expr: self.mgr.BVAnd(args
|
|
344
|
-
z3.Z3_OP_BOR : lambda args, expr: self.mgr.BVOr(args
|
|
343
|
+
z3.Z3_OP_BAND : lambda args, expr: self.mgr.BVAnd(args),
|
|
344
|
+
z3.Z3_OP_BOR : lambda args, expr: self.mgr.BVOr(args),
|
|
345
345
|
z3.Z3_OP_BXOR : lambda args, expr: self.mgr.BVXor(args[0], args[1]),
|
|
346
346
|
z3.Z3_OP_BNOT : lambda args, expr: self.mgr.BVNot(args[0]),
|
|
347
347
|
z3.Z3_OP_BNEG : lambda args, expr: self.mgr.BVNeg(args[0]),
|
|
348
|
-
z3.Z3_OP_CONCAT : lambda args, expr: self.mgr.BVConcat(args
|
|
348
|
+
z3.Z3_OP_CONCAT : lambda args, expr: self.mgr.BVConcat(args),
|
|
349
349
|
z3.Z3_OP_ULT : lambda args, expr: self.mgr.BVULT(args[0], args[1]),
|
|
350
350
|
z3.Z3_OP_ULEQ : lambda args, expr: self.mgr.BVULE(args[0], args[1]),
|
|
351
351
|
z3.Z3_OP_SLT : lambda args, expr: self.mgr.BVSLT(args[0], args[1]),
|
|
@@ -354,8 +354,8 @@ class Z3Converter(Converter, DagWalker):
|
|
|
354
354
|
z3.Z3_OP_UGEQ : lambda args, expr: self.mgr.BVUGE(args[0], args[1]),
|
|
355
355
|
z3.Z3_OP_SGT : lambda args, expr: self.mgr.BVSGT(args[0], args[1]),
|
|
356
356
|
z3.Z3_OP_SGEQ : lambda args, expr: self.mgr.BVSGE(args[0], args[1]),
|
|
357
|
-
z3.Z3_OP_BADD : lambda args, expr: self.mgr.BVAdd(args
|
|
358
|
-
z3.Z3_OP_BMUL : lambda args, expr: self.mgr.BVMul(args
|
|
357
|
+
z3.Z3_OP_BADD : lambda args, expr: self.mgr.BVAdd(args),
|
|
358
|
+
z3.Z3_OP_BMUL : lambda args, expr: self.mgr.BVMul(args),
|
|
359
359
|
z3.Z3_OP_BUDIV : lambda args, expr: self.mgr.BVUDiv(args[0], args[1]),
|
|
360
360
|
z3.Z3_OP_BSDIV : lambda args, expr: self.mgr.BVSDiv(args[0], args[1]),
|
|
361
361
|
z3.Z3_OP_BUREM : lambda args, expr: self.mgr.BVURem(args[0], args[1]),
|
|
@@ -513,6 +513,9 @@ class Z3Converter(Converter, DagWalker):
|
|
|
513
513
|
assert not len(args) > 2 or \
|
|
514
514
|
(z3.is_and(expr) or z3.is_or(expr) or
|
|
515
515
|
z3.is_add(expr) or z3.is_mul(expr) or
|
|
516
|
+
z3.is_app_of(expr, z3.Z3_OP_BAND) or z3.is_app_of(expr, z3.Z3_OP_BOR) or
|
|
517
|
+
z3.is_app_of(expr, z3.Z3_OP_BADD) or z3.is_app_of(expr, z3.Z3_OP_BMUL) or
|
|
518
|
+
z3.is_app_of(expr, z3.Z3_OP_CONCAT) or
|
|
516
519
|
(len(args) == 3 and (z3.is_ite(expr) or z3.is_array_store(expr)))),\
|
|
517
520
|
"Unexpected n-ary term: %s" % expr
|
|
518
521
|
|
|
@@ -16,11 +16,12 @@
|
|
|
16
16
|
# limitations under the License.
|
|
17
17
|
#
|
|
18
18
|
from pysmt.shortcuts import FreshSymbol, GT, And, Plus, Real, Int, LE, Iff
|
|
19
|
-
from pysmt.shortcuts import Solver
|
|
20
|
-
from pysmt.
|
|
19
|
+
from pysmt.shortcuts import Solver, Symbol, EqualsOrIff
|
|
20
|
+
from pysmt.shortcuts import BVAdd, BVMul, BVAnd, BVOr, BVConcat
|
|
21
|
+
from pysmt.typing import REAL, INT, BVType
|
|
21
22
|
from pysmt.test import TestCase, skipIfSolverNotAvailable, main
|
|
22
23
|
from pysmt.test.examples import get_example_formulae
|
|
23
|
-
from pysmt.logics import QF_UFLIRA
|
|
24
|
+
from pysmt.logics import QF_UFLIRA, QF_BV
|
|
24
25
|
from pysmt.exceptions import NoSolverAvailableError
|
|
25
26
|
|
|
26
27
|
|
|
@@ -87,6 +88,31 @@ class TestBasic(TestCase):
|
|
|
87
88
|
self.do_back("z3", via_smtlib=True)
|
|
88
89
|
self.do_back("z3", via_smtlib=False)
|
|
89
90
|
|
|
91
|
+
@skipIfSolverNotAvailable("z3")
|
|
92
|
+
def test_z3_back_nary_bv(self):
|
|
93
|
+
# Z3 simplification can produce n-ary (more than two arguments)
|
|
94
|
+
# bit-vector operations. Back-converting them used to fail because
|
|
95
|
+
# only the binary case was handled (unlike the integer operations).
|
|
96
|
+
import z3 # type: ignore[import]
|
|
97
|
+
|
|
98
|
+
s = Solver(name="z3", logic=QF_BV)
|
|
99
|
+
conv = s.converter
|
|
100
|
+
a = Symbol("a", BVType(8))
|
|
101
|
+
b = Symbol("b", BVType(8))
|
|
102
|
+
c = Symbol("c", BVType(8))
|
|
103
|
+
|
|
104
|
+
for f in (BVAdd(BVAdd(a, b), c),
|
|
105
|
+
BVMul(BVMul(a, b), c),
|
|
106
|
+
BVAnd(BVAnd(a, b), c),
|
|
107
|
+
BVOr(BVOr(a, b), c),
|
|
108
|
+
BVConcat(BVConcat(a, b), c)):
|
|
109
|
+
# Simplify in Z3 to flatten the associative operators into a
|
|
110
|
+
# single n-ary application before converting back.
|
|
111
|
+
simplified = z3.simplify(conv.convert(f))
|
|
112
|
+
res = conv.back(simplified)
|
|
113
|
+
self.assertValid(EqualsOrIff(f, res), logic=QF_BV,
|
|
114
|
+
solver_name="z3")
|
|
115
|
+
|
|
90
116
|
|
|
91
117
|
if __name__ == '__main__':
|
|
92
118
|
main()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|