3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-27 10:55:50 +00:00

Adding some options in support of F* (#6774)

* patterns: add option for pattern decomposition (pi.decompose_patterns)

True by default, retaining current behavior.

* rewriter: add option for sorting of disjunctions (rewriter.sort_disjunctions)

True by default, retaining current behavior.
This commit is contained in:
Guido Martínez 2023-06-20 16:10:37 -07:00 committed by GitHub
parent eb1caee18a
commit 3517361a73
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 14 additions and 2 deletions

View file

@ -109,6 +109,7 @@ pattern_inference_cfg::pattern_inference_cfg(ast_manager & m, pattern_inference_
m_le(),
m_nested_arith_only(true),
m_block_loop_patterns(params.m_pi_block_loop_patterns),
m_decompose_patterns(params.m_pi_decompose_patterns),
m_candidates(m),
m_pattern_weight_lt(m_candidates_info),
m_collect(m, *this),
@ -407,6 +408,9 @@ bool pattern_inference_cfg::pattern_weight_lt::operator()(expr * n1, expr * n2)
app* pattern_inference_cfg::mk_pattern(app* candidate) {
if (!m_decompose_patterns)
return m.mk_pattern(candidate);
auto has_var_arg = [&](expr* e) {
if (!is_app(e))
return false;

View file

@ -70,6 +70,7 @@ class pattern_inference_cfg : public default_rewriter_cfg {
expr * const * m_no_patterns;
bool m_nested_arith_only;
bool m_block_loop_patterns;
bool m_decompose_patterns;
struct info {
uint_set m_free_vars;