mirror of
https://github.com/Z3Prover/z3
synced 2025-06-12 09:03:26 +00:00
Merge branch 'master' into polysat
This commit is contained in:
commit
220a63e8bd
223 changed files with 508 additions and 505 deletions
6
.github/workflows/android-build.yml
vendored
6
.github/workflows/android-build.yml
vendored
|
@ -13,7 +13,7 @@ permissions:
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
|
@ -27,10 +27,10 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCMAKE_SYSTEM_NAME=Android -DCMAKE_SYSTEM_VERSION=21 -DCMAKE_ANDROID_ARCH_ABI=${{ matrix.android-abi }} -DCMAKE_ANDROID_NDK=$ANDROID_NDK_HOME -DZ3_BUILD_JAVA_BINDINGS=TRUE -G "Unix Makefiles" -DJAVA_AWT_LIBRARY=NotNeeded -DJAVA_JVM_LIBRARY=NotNeeded -DJAVA_INCLUDE_PATH2=NotNeeded -DJAVA_AWT_INCLUDE_PATH=NotNeeded ../
|
cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCMAKE_SYSTEM_NAME=Android -DCMAKE_SYSTEM_VERSION=21 -DCMAKE_ANDROID_ARCH_ABI=${{ matrix.android-abi }} "-DCMAKE_ANDROID_NDK=$ANDROID_NDK_LATEST_HOME" -DZ3_BUILD_JAVA_BINDINGS=TRUE -G "Unix Makefiles" -DJAVA_AWT_LIBRARY=NotNeeded -DJAVA_JVM_LIBRARY=NotNeeded -DJAVA_INCLUDE_PATH2=NotNeeded -DJAVA_AWT_INCLUDE_PATH=NotNeeded ../
|
||||||
make -j $(nproc)
|
make -j $(nproc)
|
||||||
tar -cvf z3-build-${{ matrix.android-abi }}.tar *.jar *.so
|
tar -cvf z3-build-${{ matrix.android-abi }}.tar *.jar *.so
|
||||||
|
|
||||||
- name: Archive production artifacts
|
- name: Archive production artifacts
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
cmake_minimum_required(VERSION 3.4)
|
cmake_minimum_required(VERSION 3.4)
|
||||||
|
|
||||||
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cxx_compiler_flags_overrides.cmake")
|
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cxx_compiler_flags_overrides.cmake")
|
||||||
project(Z3 VERSION 4.9.2.0 LANGUAGES CXX C)
|
project(Z3 VERSION 4.11.0.0 LANGUAGES CXX C)
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# Project version
|
# Project version
|
||||||
|
|
|
@ -10,7 +10,7 @@ Pre-built binaries for stable and nightly releases are available from [here](htt
|
||||||
Z3 can be built using [Visual Studio][1], a [Makefile][2] or using [CMake][3]. It provides
|
Z3 can be built using [Visual Studio][1], a [Makefile][2] or using [CMake][3]. It provides
|
||||||
[bindings for several programming languages][4].
|
[bindings for several programming languages][4].
|
||||||
|
|
||||||
See the [release notes](RELEASE_NOTES) for notes on various stable releases of Z3.
|
See the [release notes](RELEASE_NOTES.md) for notes on various stable releases of Z3.
|
||||||
|
|
||||||
## Build status
|
## Build status
|
||||||
|
|
||||||
|
|
|
@ -10,6 +10,19 @@ Version 4.next
|
||||||
- native word level bit-vector solving.
|
- native word level bit-vector solving.
|
||||||
- introduction of simple induction lemmas to handle a limited repertoire of induction proofs.
|
- introduction of simple induction lemmas to handle a limited repertoire of induction proofs.
|
||||||
|
|
||||||
|
Version 4.11.0
|
||||||
|
==============
|
||||||
|
- remove Z3_bool from API
|
||||||
|
|
||||||
|
Version 4.10.2
|
||||||
|
==============
|
||||||
|
- fix regression #6194. It broke mod/rem/div reasoning.
|
||||||
|
- fix user propagator scope management for equality callbacks.
|
||||||
|
|
||||||
|
Version 4.10.1
|
||||||
|
==============
|
||||||
|
- fix implementation of mk_fresh in user propagator for Python API
|
||||||
|
|
||||||
Version 4.10.0
|
Version 4.10.0
|
||||||
==============
|
==============
|
||||||
- Added API Z3_enable_concurrent_dec_ref to be set by interfaces that
|
- Added API Z3_enable_concurrent_dec_ref to be set by interfaces that
|
||||||
|
@ -39,6 +52,7 @@ Version 4.10.0
|
||||||
of the form x = 0
|
of the form x = 0
|
||||||
- After (partial) completion, perform factorization for factors of the
|
- After (partial) completion, perform factorization for factors of the
|
||||||
form x*y*p = 0 where x, are variables, p is linear.
|
form x*y*p = 0 where x, are variables, p is linear.
|
||||||
|
- Added support for declaring algebraic datatypes from the C++ interface.
|
||||||
|
|
||||||
|
|
||||||
Version 4.9.1
|
Version 4.9.1
|
||||||
|
|
|
@ -2171,7 +2171,6 @@ INCLUDE_FILE_PATTERNS =
|
||||||
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
|
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
|
||||||
|
|
||||||
PREDEFINED = Z3_ast_opt:=Z3_ast \
|
PREDEFINED = Z3_ast_opt:=Z3_ast \
|
||||||
Z3_bool_opt:=Z3_bool \
|
|
||||||
Z3_func_interp_opt:=Z3_func_interp \
|
Z3_func_interp_opt:=Z3_func_interp \
|
||||||
Z3_model_opt:=Z3_model \
|
Z3_model_opt:=Z3_model \
|
||||||
__out_opt:=__out
|
__out_opt:=__out
|
||||||
|
|
|
@ -816,7 +816,7 @@ INCLUDE_FILE_PATTERNS =
|
||||||
# undefined via #undef or recursively expanded use the := operator
|
# undefined via #undef or recursively expanded use the := operator
|
||||||
# instead of the = operator.
|
# instead of the = operator.
|
||||||
|
|
||||||
PREDEFINED =Z3_ast_opt:=Z3_ast Z3_bool_opt:=Z3_bool Z3_func_interp_opt:=Z3_func_interp Z3_model_opt:=Z3_model __out_opt:=__out
|
PREDEFINED =Z3_ast_opt:=Z3_ast Z3_func_interp_opt:=Z3_func_interp Z3_model_opt:=Z3_model __out_opt:=__out
|
||||||
|
|
||||||
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then
|
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then
|
||||||
# this tag can be used to specify a list of macro names that should be expanded.
|
# this tag can be used to specify a list of macro names that should be expanded.
|
||||||
|
@ -825,7 +825,7 @@ PREDEFINED =Z3_ast_opt:=Z3_ast Z3_bool_opt:=Z3_bool Z3_func_interp_o
|
||||||
|
|
||||||
EXPAND_AS_DEFINED =
|
EXPAND_AS_DEFINED =
|
||||||
|
|
||||||
# Z3_ast_opt Z3_bool_opt Z3_func_interp_opt Z3_model_opt __out_opt
|
# Z3_ast_opt Z3_func_interp_opt Z3_model_opt __out_opt
|
||||||
|
|
||||||
# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then
|
# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then
|
||||||
# doxygen's preprocessor will remove all function-like macros that are alone
|
# doxygen's preprocessor will remove all function-like macros that are alone
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
from mk_util import *
|
from mk_util import *
|
||||||
|
|
||||||
def init_version():
|
def init_version():
|
||||||
set_version(4, 9, 2, 0)
|
set_version(4, 11, 0, 0)
|
||||||
|
|
||||||
# Z3 Project definition
|
# Z3 Project definition
|
||||||
def init_project_def():
|
def init_project_def():
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
variables:
|
variables:
|
||||||
|
|
||||||
Major: '4'
|
Major: '4'
|
||||||
Minor: '9'
|
Minor: '11'
|
||||||
Patch: '2'
|
Patch: '0'
|
||||||
NightlyVersion: $(Major).$(Minor).$(Patch).$(Build.BuildId)-$(Build.DefinitionName)
|
NightlyVersion: $(Major).$(Minor).$(Patch).$(Build.BuildId)-$(Build.DefinitionName)
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
trigger: none
|
trigger: none
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
ReleaseVersion: '4.9.2'
|
ReleaseVersion: '4.11.0'
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
|
|
||||||
|
@ -516,8 +516,9 @@ stages:
|
||||||
inputs:
|
inputs:
|
||||||
command: push
|
command: push
|
||||||
nuGetFeedType: External
|
nuGetFeedType: External
|
||||||
publishFeedCredentials: Z3Nuget
|
publishFeedCredentials: $(NugetZ3)
|
||||||
packagesToPush: $(Agent.TempDirectory)/*.nupkg
|
packagesToPush: $(Agent.TempDirectory)/*.nupkg
|
||||||
|
|
||||||
|
|
||||||
# Enable on release:
|
# Enable on release:
|
||||||
- job: PyPIPublish
|
- job: PyPIPublish
|
||||||
|
|
|
@ -1854,6 +1854,7 @@ _lib.Z3_solver_propagate_final.restype = None
|
||||||
_lib.Z3_solver_propagate_fixed.restype = None
|
_lib.Z3_solver_propagate_fixed.restype = None
|
||||||
_lib.Z3_solver_propagate_eq.restype = None
|
_lib.Z3_solver_propagate_eq.restype = None
|
||||||
_lib.Z3_solver_propagate_diseq.restype = None
|
_lib.Z3_solver_propagate_diseq.restype = None
|
||||||
|
_lib.Z3_solver_propagate_decide.restype = None
|
||||||
|
|
||||||
on_model_eh_type = ctypes.CFUNCTYPE(None, ctypes.c_void_p)
|
on_model_eh_type = ctypes.CFUNCTYPE(None, ctypes.c_void_p)
|
||||||
_lib.Z3_optimize_register_model_eh.restype = None
|
_lib.Z3_optimize_register_model_eh.restype = None
|
||||||
|
|
|
@ -29,8 +29,6 @@ public:
|
||||||
updt_params(p);
|
updt_params(p);
|
||||||
}
|
}
|
||||||
|
|
||||||
~ackermannize_bv_tactic() override { }
|
|
||||||
|
|
||||||
char const* name() const override { return "ackermannize_bv"; }
|
char const* name() const override { return "ackermannize_bv"; }
|
||||||
|
|
||||||
void operator()(goal_ref const & g, goal_ref_buffer & result) override {
|
void operator()(goal_ref const & g, goal_ref_buffer & result) override {
|
||||||
|
|
|
@ -40,8 +40,6 @@ public:
|
||||||
fixed_model(false)
|
fixed_model(false)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
~ackr_model_converter() override { }
|
|
||||||
|
|
||||||
void get_units(obj_map<expr, bool>& units) override { units.reset(); }
|
void get_units(obj_map<expr, bool>& units) override { units.reset(); }
|
||||||
|
|
||||||
void operator()(model_ref & md) override {
|
void operator()(model_ref & md) override {
|
||||||
|
|
|
@ -28,8 +28,6 @@ public:
|
||||||
, model_constructor(lmc)
|
, model_constructor(lmc)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
~lackr_model_converter_lazy() override { }
|
|
||||||
|
|
||||||
void operator()(model_ref & md) override {
|
void operator()(model_ref & md) override {
|
||||||
SASSERT(md.get() == 0 || (!md->get_num_constants() && !md->get_num_functions()));
|
SASSERT(md.get() == 0 || (!md->get_num_constants() && !md->get_num_functions()));
|
||||||
SASSERT(model_constructor.get());
|
SASSERT(model_constructor.get());
|
||||||
|
|
|
@ -344,7 +344,6 @@ extern "C" {
|
||||||
scoped_anum_vector const & m_as;
|
scoped_anum_vector const & m_as;
|
||||||
public:
|
public:
|
||||||
vector_var2anum(scoped_anum_vector & as):m_as(as) {}
|
vector_var2anum(scoped_anum_vector & as):m_as(as) {}
|
||||||
virtual ~vector_var2anum() {}
|
|
||||||
algebraic_numbers::manager & m() const override { return m_as.m(); }
|
algebraic_numbers::manager & m() const override { return m_as.m(); }
|
||||||
bool contains(polynomial::var x) const override { return static_cast<unsigned>(x) < m_as.size(); }
|
bool contains(polynomial::var x) const override { return static_cast<unsigned>(x) < m_as.size(); }
|
||||||
algebraic_numbers::anum const & operator()(polynomial::var x) const override { return m_as.get(x); }
|
algebraic_numbers::anum const & operator()(polynomial::var x) const override { return m_as.get(x); }
|
||||||
|
|
|
@ -26,7 +26,6 @@ namespace api {
|
||||||
struct Z3_ast_vector_ref : public api::object {
|
struct Z3_ast_vector_ref : public api::object {
|
||||||
ast_ref_vector m_ast_vector;
|
ast_ref_vector m_ast_vector;
|
||||||
Z3_ast_vector_ref(api::context& c, ast_manager & m): api::object(c), m_ast_vector(m) {}
|
Z3_ast_vector_ref(api::context& c, ast_manager & m): api::object(c), m_ast_vector(m) {}
|
||||||
~Z3_ast_vector_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_ast_vector_ref * to_ast_vector(Z3_ast_vector v) { return reinterpret_cast<Z3_ast_vector_ref *>(v); }
|
inline Z3_ast_vector_ref * to_ast_vector(Z3_ast_vector v) { return reinterpret_cast<Z3_ast_vector_ref *>(v); }
|
||||||
|
|
|
@ -47,7 +47,7 @@ extern "C" {
|
||||||
env_params::updt_params();
|
env_params::updt_params();
|
||||||
}
|
}
|
||||||
|
|
||||||
Z3_bool Z3_API Z3_global_param_get(Z3_string param_id, Z3_string_ptr param_value) {
|
bool Z3_API Z3_global_param_get(Z3_string param_id, Z3_string_ptr param_value) {
|
||||||
memory::initialize(UINT_MAX);
|
memory::initialize(UINT_MAX);
|
||||||
LOG_Z3_global_param_get(param_id, param_value);
|
LOG_Z3_global_param_get(param_id, param_value);
|
||||||
*param_value = nullptr;
|
*param_value = nullptr;
|
||||||
|
|
|
@ -58,7 +58,7 @@ namespace api {
|
||||||
solver_ref s;
|
solver_ref s;
|
||||||
public:
|
public:
|
||||||
seq_expr_solver(ast_manager& m, params_ref const& p): m(m), p(p) {}
|
seq_expr_solver(ast_manager& m, params_ref const& p): m(m), p(p) {}
|
||||||
lbool check_sat(expr* e) {
|
lbool check_sat(expr* e) override {
|
||||||
if (!s) {
|
if (!s) {
|
||||||
s = mk_smt_solver(m, p, symbol("ALL"));
|
s = mk_smt_solver(m, p, symbol("ALL"));
|
||||||
}
|
}
|
||||||
|
|
|
@ -52,7 +52,6 @@ namespace api {
|
||||||
m_context(m, m_register_engine, p),
|
m_context(m, m_register_engine, p),
|
||||||
m_trail(m) {}
|
m_trail(m) {}
|
||||||
|
|
||||||
~fixedpoint_context() override {}
|
|
||||||
family_id get_family_id() const override { return const_cast<datalog::context&>(m_context).get_decl_util().get_family_id(); }
|
family_id get_family_id() const override { return const_cast<datalog::context&>(m_context).get_decl_util().get_family_id(); }
|
||||||
void set_state(void* state) {
|
void set_state(void* state) {
|
||||||
SASSERT(!m_state);
|
SASSERT(!m_state);
|
||||||
|
|
|
@ -23,7 +23,6 @@ Revision History:
|
||||||
struct Z3_goal_ref : public api::object {
|
struct Z3_goal_ref : public api::object {
|
||||||
goal_ref m_goal;
|
goal_ref m_goal;
|
||||||
Z3_goal_ref(api::context& c) : api::object(c) {}
|
Z3_goal_ref(api::context& c) : api::object(c) {}
|
||||||
~Z3_goal_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_goal_ref * to_goal(Z3_goal g) { return reinterpret_cast<Z3_goal_ref *>(g); }
|
inline Z3_goal_ref * to_goal(Z3_goal g) { return reinterpret_cast<Z3_goal_ref *>(g); }
|
||||||
|
|
|
@ -23,7 +23,6 @@ Revision History:
|
||||||
struct Z3_model_ref : public api::object {
|
struct Z3_model_ref : public api::object {
|
||||||
model_ref m_model;
|
model_ref m_model;
|
||||||
Z3_model_ref(api::context& c): api::object(c) {}
|
Z3_model_ref(api::context& c): api::object(c) {}
|
||||||
~Z3_model_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_model_ref * to_model(Z3_model s) { return reinterpret_cast<Z3_model_ref *>(s); }
|
inline Z3_model_ref * to_model(Z3_model s) { return reinterpret_cast<Z3_model_ref *>(s); }
|
||||||
|
@ -34,7 +33,6 @@ struct Z3_func_interp_ref : public api::object {
|
||||||
model_ref m_model; // must have it to prevent reference to m_func_interp to be killed.
|
model_ref m_model; // must have it to prevent reference to m_func_interp to be killed.
|
||||||
func_interp * m_func_interp;
|
func_interp * m_func_interp;
|
||||||
Z3_func_interp_ref(api::context& c, model * m): api::object(c), m_model(m), m_func_interp(nullptr) {}
|
Z3_func_interp_ref(api::context& c, model * m): api::object(c), m_model(m), m_func_interp(nullptr) {}
|
||||||
~Z3_func_interp_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_func_interp_ref * to_func_interp(Z3_func_interp s) { return reinterpret_cast<Z3_func_interp_ref *>(s); }
|
inline Z3_func_interp_ref * to_func_interp(Z3_func_interp s) { return reinterpret_cast<Z3_func_interp_ref *>(s); }
|
||||||
|
@ -46,7 +44,6 @@ struct Z3_func_entry_ref : public api::object {
|
||||||
func_interp * m_func_interp;
|
func_interp * m_func_interp;
|
||||||
func_entry const * m_func_entry;
|
func_entry const * m_func_entry;
|
||||||
Z3_func_entry_ref(api::context& c, model * m):api::object(c), m_model(m), m_func_interp(nullptr), m_func_entry(nullptr) {}
|
Z3_func_entry_ref(api::context& c, model * m):api::object(c), m_model(m), m_func_interp(nullptr), m_func_entry(nullptr) {}
|
||||||
~Z3_func_entry_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_func_entry_ref * to_func_entry(Z3_func_entry s) { return reinterpret_cast<Z3_func_entry_ref *>(s); }
|
inline Z3_func_entry_ref * to_func_entry(Z3_func_entry s) { return reinterpret_cast<Z3_func_entry_ref *>(s); }
|
||||||
|
|
|
@ -459,4 +459,33 @@ extern "C" {
|
||||||
Z3_CATCH_RETURN(nullptr);
|
Z3_CATCH_RETURN(nullptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
Z3_ast Z3_API Z3_mk_mpz_numeral(Z3_context c, bool sign, unsigned n, unsigned const nums[], Z3_sort* srt) {
|
||||||
|
LOG_TRY;
|
||||||
|
LOG_Z3_mk_mpz_numeral(c, sign, n, nums, srt);
|
||||||
|
RESET_ERROR_CODE();
|
||||||
|
rational z;
|
||||||
|
|
||||||
|
// todo fill in z
|
||||||
|
if (!z.size())
|
||||||
|
z.neg();
|
||||||
|
arith_util & a = mk_c(c)->autil();
|
||||||
|
auto* a = mk_c(c)->mk_numeral_core(r, a.mk_int_sort());
|
||||||
|
Z3_CATCH_RETURN(nullptr);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
Z3_ast Z3_API Z3_mk_mpq_numeral1(Z3_context c, bool sign, unsigned n, unsigned const nums[], unsigned d, unsigned const dens[]) {
|
||||||
|
LOG_TRY;
|
||||||
|
LOG_Z3_mk_mpq_numeral(c, sign, n, nums, d, dens);
|
||||||
|
RESET_ERROR_CODE();
|
||||||
|
rational q;
|
||||||
|
|
||||||
|
if (!sign)
|
||||||
|
q.neg();
|
||||||
|
|
||||||
|
Z3_CATCH_RETURN(nullptr);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -47,8 +47,6 @@ extern "C" {
|
||||||
ctx->register_plist();
|
ctx->register_plist();
|
||||||
ctx->set_ignore_check(true);
|
ctx->set_ignore_check(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
~Z3_parser_context_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_parser_context_ref * to_parser_context(Z3_parser_context pc) { return reinterpret_cast<Z3_parser_context_ref*>(pc); }
|
inline Z3_parser_context_ref * to_parser_context(Z3_parser_context pc) { return reinterpret_cast<Z3_parser_context_ref*>(pc); }
|
||||||
|
|
|
@ -51,7 +51,6 @@ struct Z3_solver_ref : public api::object {
|
||||||
|
|
||||||
Z3_solver_ref(api::context& c, solver_factory * f):
|
Z3_solver_ref(api::context& c, solver_factory * f):
|
||||||
api::object(c), m_solver_factory(f), m_solver(nullptr), m_logic(symbol::null), m_eh(nullptr) {}
|
api::object(c), m_solver_factory(f), m_solver(nullptr), m_logic(symbol::null), m_eh(nullptr) {}
|
||||||
~Z3_solver_ref() override {}
|
|
||||||
|
|
||||||
void assert_expr(expr* e);
|
void assert_expr(expr* e);
|
||||||
void assert_expr(expr* e, expr* t);
|
void assert_expr(expr* e, expr* t);
|
||||||
|
|
|
@ -23,7 +23,6 @@ Revision History:
|
||||||
struct Z3_stats_ref : public api::object {
|
struct Z3_stats_ref : public api::object {
|
||||||
statistics m_stats;
|
statistics m_stats;
|
||||||
Z3_stats_ref(api::context& c): api::object(c) {}
|
Z3_stats_ref(api::context& c): api::object(c) {}
|
||||||
~Z3_stats_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_stats_ref * to_stats(Z3_stats s) { return reinterpret_cast<Z3_stats_ref *>(s); }
|
inline Z3_stats_ref * to_stats(Z3_stats s) { return reinterpret_cast<Z3_stats_ref *>(s); }
|
||||||
|
|
|
@ -28,13 +28,11 @@ namespace api {
|
||||||
struct Z3_tactic_ref : public api::object {
|
struct Z3_tactic_ref : public api::object {
|
||||||
tactic_ref m_tactic;
|
tactic_ref m_tactic;
|
||||||
Z3_tactic_ref(api::context& c): api::object(c) {}
|
Z3_tactic_ref(api::context& c): api::object(c) {}
|
||||||
~Z3_tactic_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct Z3_probe_ref : public api::object {
|
struct Z3_probe_ref : public api::object {
|
||||||
probe_ref m_probe;
|
probe_ref m_probe;
|
||||||
Z3_probe_ref(api::context& c):api::object(c) {}
|
Z3_probe_ref(api::context& c):api::object(c) {}
|
||||||
~Z3_probe_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_tactic_ref * to_tactic(Z3_tactic g) { return reinterpret_cast<Z3_tactic_ref *>(g); }
|
inline Z3_tactic_ref * to_tactic(Z3_tactic g) { return reinterpret_cast<Z3_tactic_ref *>(g); }
|
||||||
|
@ -50,7 +48,6 @@ struct Z3_apply_result_ref : public api::object {
|
||||||
model_converter_ref m_mc;
|
model_converter_ref m_mc;
|
||||||
proof_converter_ref m_pc;
|
proof_converter_ref m_pc;
|
||||||
Z3_apply_result_ref(api::context& c, ast_manager & m);
|
Z3_apply_result_ref(api::context& c, ast_manager & m);
|
||||||
~Z3_apply_result_ref() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline Z3_apply_result_ref * to_apply_result(Z3_apply_result g) { return reinterpret_cast<Z3_apply_result_ref *>(g); }
|
inline Z3_apply_result_ref * to_apply_result(Z3_apply_result g) { return reinterpret_cast<Z3_apply_result_ref *>(g); }
|
||||||
|
|
|
@ -3414,7 +3414,7 @@ namespace z3 {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
constructor_list::constructor_list(constructors const& cs): ctx(cs.ctx) {
|
inline constructor_list::constructor_list(constructors const& cs): ctx(cs.ctx) {
|
||||||
array<Z3_constructor> cons(cs.size());
|
array<Z3_constructor> cons(cs.size());
|
||||||
for (unsigned i = 0; i < cs.size(); ++i)
|
for (unsigned i = 0; i < cs.size(); ++i)
|
||||||
cons[i] = cs[i];
|
cons[i] = cs[i];
|
||||||
|
|
|
@ -938,6 +938,15 @@ namespace Microsoft.Z3
|
||||||
return new BoolExpr(this, Native.Z3_mk_distinct(nCtx, (uint)args.Length, AST.ArrayToNative(args)));
|
return new BoolExpr(this, Native.Z3_mk_distinct(nCtx, (uint)args.Length, AST.ArrayToNative(args)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Creates a <c>distinct</c> term.
|
||||||
|
/// </summary>
|
||||||
|
public BoolExpr MkDistinct(IEnumerable<Expr> args)
|
||||||
|
{
|
||||||
|
Debug.Assert(args != null);
|
||||||
|
return MkDistinct(args.ToArray());
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Mk an expression representing <c>not(a)</c>.
|
/// Mk an expression representing <c>not(a)</c>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -103,7 +103,7 @@ function rcf_get_numerator_denominator(c: Z3_context, a: Z3_rcf_num): { n: Z3_rc
|
||||||
When there is only a single out parameter, and the return value is not otherwise of interest, the parameter is not wrapped. For example, the C declaration
|
When there is only a single out parameter, and the return value is not otherwise of interest, the parameter is not wrapped. For example, the C declaration
|
||||||
|
|
||||||
```c
|
```c
|
||||||
Z3_bool Z3_model_eval(Z3_context c, Z3_model m, Z3_ast t, bool model_completion, Z3_ast * v);
|
bool Z3_model_eval(Z3_context c, Z3_model m, Z3_ast t, bool model_completion, Z3_ast * v);
|
||||||
```
|
```
|
||||||
|
|
||||||
is represented in the TS bindings as
|
is represented in the TS bindings as
|
||||||
|
|
|
@ -16,7 +16,6 @@ const files = [
|
||||||
|
|
||||||
const aliases = {
|
const aliases = {
|
||||||
__proto__: null,
|
__proto__: null,
|
||||||
Z3_bool: 'boolean',
|
|
||||||
Z3_string: 'string',
|
Z3_string: 'string',
|
||||||
bool: 'boolean',
|
bool: 'boolean',
|
||||||
signed: 'int',
|
signed: 'int',
|
||||||
|
|
|
@ -498,6 +498,15 @@ export function createApi(Z3: Z3Core): Z3HighLevel {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
///////////////////////////////
|
||||||
|
// expression simplification //
|
||||||
|
///////////////////////////////
|
||||||
|
|
||||||
|
async function simplify(e : Expr<Name>) {
|
||||||
|
const result = await Z3.simplify(contextPtr, e.ast)
|
||||||
|
return _toExpr(check(result));
|
||||||
|
}
|
||||||
|
|
||||||
/////////////
|
/////////////
|
||||||
// Objects //
|
// Objects //
|
||||||
/////////////
|
/////////////
|
||||||
|
@ -1050,6 +1059,10 @@ export function createApi(Z3: Z3Core): Z3HighLevel {
|
||||||
return check(Z3.model_to_string(contextPtr, this.ptr));
|
return check(Z3.model_to_string(contextPtr, this.ptr));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
toString() {
|
||||||
|
return this.sexpr();
|
||||||
|
}
|
||||||
|
|
||||||
eval(expr: Bool<Name>, modelCompletion?: boolean): Bool<Name>;
|
eval(expr: Bool<Name>, modelCompletion?: boolean): Bool<Name>;
|
||||||
eval(expr: Arith<Name>, modelCompletion?: boolean): Arith<Name>;
|
eval(expr: Arith<Name>, modelCompletion?: boolean): Arith<Name>;
|
||||||
eval(expr: Expr<Name>, modelCompletion: boolean = false) {
|
eval(expr: Expr<Name>, modelCompletion: boolean = false) {
|
||||||
|
|
|
@ -133,7 +133,7 @@ def _configure_z3():
|
||||||
# Allow command-line arguments to add and override Z3_ options
|
# Allow command-line arguments to add and override Z3_ options
|
||||||
for i in range(len(sys.argv) - 1):
|
for i in range(len(sys.argv) - 1):
|
||||||
key = sys.argv[i]
|
key = sys.argv[i]
|
||||||
if key.starts_with("Z3_"):
|
if key.startswith("Z3_"):
|
||||||
val = sys.argv[i + 1].upper()
|
val = sys.argv[i + 1].upper()
|
||||||
if val == "TRUE" or val == "FALSE":
|
if val == "TRUE" or val == "FALSE":
|
||||||
cmake_options[key] = val
|
cmake_options[key] = val
|
||||||
|
|
|
@ -204,12 +204,13 @@ class Context:
|
||||||
Z3_set_param_value(conf, str(prev), _to_param_value(a))
|
Z3_set_param_value(conf, str(prev), _to_param_value(a))
|
||||||
prev = None
|
prev = None
|
||||||
self.ctx = Z3_mk_context_rc(conf)
|
self.ctx = Z3_mk_context_rc(conf)
|
||||||
|
self.owner = True
|
||||||
self.eh = Z3_set_error_handler(self.ctx, z3_error_handler)
|
self.eh = Z3_set_error_handler(self.ctx, z3_error_handler)
|
||||||
Z3_set_ast_print_mode(self.ctx, Z3_PRINT_SMTLIB2_COMPLIANT)
|
Z3_set_ast_print_mode(self.ctx, Z3_PRINT_SMTLIB2_COMPLIANT)
|
||||||
Z3_del_config(conf)
|
Z3_del_config(conf)
|
||||||
|
|
||||||
def __del__(self):
|
def __del__(self):
|
||||||
if Z3_del_context is not None:
|
if Z3_del_context is not None and self.owner:
|
||||||
Z3_del_context(self.ctx)
|
Z3_del_context(self.ctx)
|
||||||
self.ctx = None
|
self.ctx = None
|
||||||
self.eh = None
|
self.eh = None
|
||||||
|
@ -11363,16 +11364,18 @@ def to_ContextObj(ptr,):
|
||||||
return ctx
|
return ctx
|
||||||
|
|
||||||
|
|
||||||
def user_prop_fresh(ctx, new_ctx):
|
def user_prop_fresh(ctx, _new_ctx):
|
||||||
_prop_closures.set_threaded()
|
_prop_closures.set_threaded()
|
||||||
prop = _prop_closures.get(ctx)
|
prop = _prop_closures.get(ctx)
|
||||||
nctx = Context()
|
nctx = Context()
|
||||||
new_ctx = to_ContextObj(new_ctx)
|
Z3_del_context(nctx.ctx)
|
||||||
|
new_ctx = to_ContextObj(_new_ctx)
|
||||||
nctx.ctx = new_ctx
|
nctx.ctx = new_ctx
|
||||||
nctx.eh = Z3_set_error_handler(new_ctx, z3_error_handler)
|
nctx.eh = Z3_set_error_handler(new_ctx, z3_error_handler)
|
||||||
|
nctx.owner = False
|
||||||
new_prop = prop.fresh(nctx)
|
new_prop = prop.fresh(nctx)
|
||||||
_prop_closures.set(new_prop.id, new_prop)
|
_prop_closures.set(new_prop.id, new_prop)
|
||||||
return ctypes.c_void_p(new_prop.id)
|
return new_prop.id
|
||||||
|
|
||||||
def to_Ast(ptr,):
|
def to_Ast(ptr,):
|
||||||
ast = Ast(ptr)
|
ast = Ast(ptr)
|
||||||
|
@ -11387,6 +11390,13 @@ def user_prop_fixed(ctx, cb, id, value):
|
||||||
prop.fixed(id, value)
|
prop.fixed(id, value)
|
||||||
prop.cb = None
|
prop.cb = None
|
||||||
|
|
||||||
|
def user_prop_created(ctx, cb, id):
|
||||||
|
prop = _prop_closures.get(ctx)
|
||||||
|
prop.cb = cb
|
||||||
|
id = _to_expr_ref(to_Ast(id), prop.ctx())
|
||||||
|
prop.created(id)
|
||||||
|
prop.cb = None
|
||||||
|
|
||||||
def user_prop_final(ctx, cb):
|
def user_prop_final(ctx, cb):
|
||||||
prop = _prop_closures.get(ctx)
|
prop = _prop_closures.get(ctx)
|
||||||
prop.cb = cb
|
prop.cb = cb
|
||||||
|
@ -11409,15 +11419,50 @@ def user_prop_diseq(ctx, cb, x, y):
|
||||||
prop.diseq(x, y)
|
prop.diseq(x, y)
|
||||||
prop.cb = None
|
prop.cb = None
|
||||||
|
|
||||||
|
# TODO The decision callback is not fully implemented.
|
||||||
|
# It needs to handle the ast*, unsigned* idx, and Z3_lbool*
|
||||||
|
def user_prop_decide(ctx, cb, t_ref, idx_ref, phase_ref):
|
||||||
|
prop = _prop_closures.get(ctx)
|
||||||
|
prop.cb = cb
|
||||||
|
t = _to_expr_ref(to_Ast(t_ref), prop.ctx())
|
||||||
|
t, idx, phase = prop.decide(t, idx, phase)
|
||||||
|
t_ref = t
|
||||||
|
idx_ref = idx
|
||||||
|
phase_ref = phase
|
||||||
|
prop.cb = None
|
||||||
|
|
||||||
|
|
||||||
_user_prop_push = Z3_push_eh(user_prop_push)
|
_user_prop_push = Z3_push_eh(user_prop_push)
|
||||||
_user_prop_pop = Z3_pop_eh(user_prop_pop)
|
_user_prop_pop = Z3_pop_eh(user_prop_pop)
|
||||||
_user_prop_fresh = Z3_fresh_eh(user_prop_fresh)
|
_user_prop_fresh = Z3_fresh_eh(user_prop_fresh)
|
||||||
_user_prop_fixed = Z3_fixed_eh(user_prop_fixed)
|
_user_prop_fixed = Z3_fixed_eh(user_prop_fixed)
|
||||||
|
_user_prop_created = Z3_created_eh(user_prop_created)
|
||||||
_user_prop_final = Z3_final_eh(user_prop_final)
|
_user_prop_final = Z3_final_eh(user_prop_final)
|
||||||
_user_prop_eq = Z3_eq_eh(user_prop_eq)
|
_user_prop_eq = Z3_eq_eh(user_prop_eq)
|
||||||
_user_prop_diseq = Z3_eq_eh(user_prop_diseq)
|
_user_prop_diseq = Z3_eq_eh(user_prop_diseq)
|
||||||
|
_user_prop_decide = Z3_decide_eh(user_prop_decide)
|
||||||
|
|
||||||
|
def PropagateFunction(name, *sig):
|
||||||
|
"""Create a function that gets tracked by user propagator.
|
||||||
|
Every term headed by this function symbol is tracked.
|
||||||
|
If a term is fixed and the fixed callback is registered a
|
||||||
|
callback is invoked that the term headed by this function is fixed.
|
||||||
|
"""
|
||||||
|
sig = _get_args(sig)
|
||||||
|
if z3_debug():
|
||||||
|
_z3_assert(len(sig) > 0, "At least two arguments expected")
|
||||||
|
arity = len(sig) - 1
|
||||||
|
rng = sig[arity]
|
||||||
|
if z3_debug():
|
||||||
|
_z3_assert(is_sort(rng), "Z3 sort expected")
|
||||||
|
dom = (Sort * arity)()
|
||||||
|
for i in range(arity):
|
||||||
|
if z3_debug():
|
||||||
|
_z3_assert(is_sort(sig[i]), "Z3 sort expected")
|
||||||
|
dom[i] = sig[i].ast
|
||||||
|
ctx = rng.ctx
|
||||||
|
return FuncDeclRef(Z3_solver_propagate_declare(ctx.ref(), to_symbol(name, ctx), arity, dom, rng.ast), ctx)
|
||||||
|
|
||||||
|
|
||||||
class UserPropagateBase:
|
class UserPropagateBase:
|
||||||
|
|
||||||
|
@ -11440,6 +11485,7 @@ class UserPropagateBase:
|
||||||
self.final = None
|
self.final = None
|
||||||
self.eq = None
|
self.eq = None
|
||||||
self.diseq = None
|
self.diseq = None
|
||||||
|
self.created = None
|
||||||
if ctx:
|
if ctx:
|
||||||
self.fresh_ctx = ctx
|
self.fresh_ctx = ctx
|
||||||
if s:
|
if s:
|
||||||
|
@ -11470,6 +11516,13 @@ class UserPropagateBase:
|
||||||
Z3_solver_propagate_fixed(self.ctx_ref(), self.solver.solver, _user_prop_fixed)
|
Z3_solver_propagate_fixed(self.ctx_ref(), self.solver.solver, _user_prop_fixed)
|
||||||
self.fixed = fixed
|
self.fixed = fixed
|
||||||
|
|
||||||
|
def add_created(self, created):
|
||||||
|
assert not self.created
|
||||||
|
assert not self._ctx
|
||||||
|
if self.solver:
|
||||||
|
Z3_solver_propagate_created(self.ctx_ref(), self.solver.solver, _user_prop_created)
|
||||||
|
self.created = created
|
||||||
|
|
||||||
def add_final(self, final):
|
def add_final(self, final):
|
||||||
assert not self.final
|
assert not self.final
|
||||||
assert not self._ctx
|
assert not self._ctx
|
||||||
|
@ -11491,6 +11544,13 @@ class UserPropagateBase:
|
||||||
Z3_solver_propagate_diseq(self.ctx_ref(), self.solver.solver, _user_prop_diseq)
|
Z3_solver_propagate_diseq(self.ctx_ref(), self.solver.solver, _user_prop_diseq)
|
||||||
self.diseq = diseq
|
self.diseq = diseq
|
||||||
|
|
||||||
|
def add_decide(self, decide):
|
||||||
|
assert not self.decide
|
||||||
|
assert not self._ctx
|
||||||
|
if self.solver:
|
||||||
|
Z3_solver_propagate_decide(self.ctx_ref(), self.solver.solver, _user_prop_decide)
|
||||||
|
self.decide = decide
|
||||||
|
|
||||||
def push(self):
|
def push(self):
|
||||||
raise Z3Exception("push needs to be overwritten")
|
raise Z3Exception("push needs to be overwritten")
|
||||||
|
|
||||||
|
@ -11501,10 +11561,20 @@ class UserPropagateBase:
|
||||||
raise Z3Exception("fresh needs to be overwritten")
|
raise Z3Exception("fresh needs to be overwritten")
|
||||||
|
|
||||||
def add(self, e):
|
def add(self, e):
|
||||||
assert self.solver
|
|
||||||
assert not self._ctx
|
assert not self._ctx
|
||||||
Z3_solver_propagate_register(self.ctx_ref(), self.solver.solver, e.ast)
|
if self.solver:
|
||||||
|
Z3_solver_propagate_register(self.ctx_ref(), self.solver.solver, e.ast)
|
||||||
|
else:
|
||||||
|
Z3_solver_propagate_register_cb(self.ctx_ref(), ctypes.c_void_p(self.cb), e.ast)
|
||||||
|
|
||||||
|
#
|
||||||
|
# Tell the solver to perform the next split on a given term
|
||||||
|
# If the term is a bit-vector the index idx specifies the index of the Boolean variable being
|
||||||
|
# split on. A phase of true = 1/false = -1/undef = 0 = let solver decide is the last argument.
|
||||||
|
#
|
||||||
|
def next_split(self, t, idx, phase):
|
||||||
|
Z3_solver_next_split(self.ctx_ref(), ctypes.c_void_p(self.cb), t.ast, idx, phase)
|
||||||
|
|
||||||
#
|
#
|
||||||
# Propagation can only be invoked as during a fixed or final callback.
|
# Propagation can only be invoked as during a fixed or final callback.
|
||||||
#
|
#
|
||||||
|
@ -11516,5 +11586,5 @@ class UserPropagateBase:
|
||||||
Z3_solver_propagate_consequence(e.ctx.ref(), ctypes.c_void_p(
|
Z3_solver_propagate_consequence(e.ctx.ref(), ctypes.c_void_p(
|
||||||
self.cb), num_fixed, _ids, num_eqs, _lhs, _rhs, e.ast)
|
self.cb), num_fixed, _ids, num_eqs, _lhs, _rhs, e.ast)
|
||||||
|
|
||||||
def conflict(self, deps):
|
def conflict(self, deps = [], eqs = []):
|
||||||
self.propagate(BoolVal(False, self.ctx()), deps, eqs=[])
|
self.propagate(BoolVal(False, self.ctx()), deps, eqs)
|
||||||
|
|
|
@ -1528,7 +1528,7 @@ extern "C" {
|
||||||
|
|
||||||
def_API('Z3_global_param_get', BOOL, (_in(STRING), _out(STRING)))
|
def_API('Z3_global_param_get', BOOL, (_in(STRING), _out(STRING)))
|
||||||
*/
|
*/
|
||||||
Z3_bool Z3_API Z3_global_param_get(Z3_string param_id, Z3_string_ptr param_value);
|
bool Z3_API Z3_global_param_get(Z3_string param_id, Z3_string_ptr param_value);
|
||||||
|
|
||||||
/**@}*/
|
/**@}*/
|
||||||
|
|
||||||
|
@ -3387,6 +3387,39 @@ extern "C" {
|
||||||
*/
|
*/
|
||||||
Z3_ast Z3_API Z3_mk_numeral(Z3_context c, Z3_string numeral, Z3_sort ty);
|
Z3_ast Z3_API Z3_mk_numeral(Z3_context c, Z3_string numeral, Z3_sort ty);
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
/**
|
||||||
|
\brief Create an integer numeral from a vector of unsigned numerals.
|
||||||
|
|
||||||
|
\param c - context
|
||||||
|
\param sign - true if positive, false if negative
|
||||||
|
\param n - length of array of numerals
|
||||||
|
\param nums - array of numerals
|
||||||
|
\param s - sort of numeral (int, real, bit-vector).
|
||||||
|
|
||||||
|
future_('Z3_mk_mpz_numeral', AST, (_in(CONTEXT), _in(BOOL), _in(UINT), _in_array(2, UINT), _in(SORT)))
|
||||||
|
*/
|
||||||
|
|
||||||
|
Z3_ast Z3_mk_mpz_numeral(Z3_context c, bool sign, unsigned n, unsigned const nums[], Z3_sort s);
|
||||||
|
|
||||||
|
/**
|
||||||
|
\brief Create a rational numeral from a vector of unsigned numerals.
|
||||||
|
|
||||||
|
\param c - context
|
||||||
|
\param sign - true if positive, false if negative
|
||||||
|
\param n - length of array of nominator numerals
|
||||||
|
\param nums - array of numerator numerals
|
||||||
|
\param d - length of array of denominator numerals
|
||||||
|
\param dens - array of denominator numerals
|
||||||
|
|
||||||
|
The sort of returned numeral is Real.
|
||||||
|
|
||||||
|
future_('Z3_mk_mpq_numeral', AST, (_in(CONTEXT), _in(BOOL), _in(UINT), _in_array(2, UINT), _in(UINT), _in_array(4, UINT)))
|
||||||
|
*/
|
||||||
|
|
||||||
|
Z3_ast Z3_mk_mpq_numeral(Z3_context c, bool sign, unsigned n, unsigned const nums[], unsigned d, unsigned const dens[]);
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
\brief Create a real from a fraction.
|
\brief Create a real from a fraction.
|
||||||
|
|
||||||
|
@ -4407,7 +4440,7 @@ extern "C" {
|
||||||
|
|
||||||
def_API('Z3_get_finite_domain_sort_size', BOOL, (_in(CONTEXT), _in(SORT), _out(UINT64)))
|
def_API('Z3_get_finite_domain_sort_size', BOOL, (_in(CONTEXT), _in(SORT), _out(UINT64)))
|
||||||
*/
|
*/
|
||||||
Z3_bool Z3_API Z3_get_finite_domain_sort_size(Z3_context c, Z3_sort s, uint64_t* r);
|
bool Z3_API Z3_get_finite_domain_sort_size(Z3_context c, Z3_sort s, uint64_t* r);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
\brief Return the domain of the given array sort.
|
\brief Return the domain of the given array sort.
|
||||||
|
@ -4822,6 +4855,8 @@ extern "C" {
|
||||||
\brief Return the number of argument of an application. If \c t
|
\brief Return the number of argument of an application. If \c t
|
||||||
is an constant, then the number of arguments is 0.
|
is an constant, then the number of arguments is 0.
|
||||||
|
|
||||||
|
\sa Z3_get_app_arg
|
||||||
|
|
||||||
def_API('Z3_get_app_num_args', UINT, (_in(CONTEXT), _in(APP)))
|
def_API('Z3_get_app_num_args', UINT, (_in(CONTEXT), _in(APP)))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_get_app_num_args(Z3_context c, Z3_app a);
|
unsigned Z3_API Z3_get_app_num_args(Z3_context c, Z3_app a);
|
||||||
|
@ -4831,6 +4866,8 @@ extern "C" {
|
||||||
|
|
||||||
\pre i < Z3_get_app_num_args(c, a)
|
\pre i < Z3_get_app_num_args(c, a)
|
||||||
|
|
||||||
|
\sa Z3_get_app_num_args
|
||||||
|
|
||||||
def_API('Z3_get_app_arg', AST, (_in(CONTEXT), _in(APP), _in(UINT)))
|
def_API('Z3_get_app_arg', AST, (_in(CONTEXT), _in(APP), _in(UINT)))
|
||||||
*/
|
*/
|
||||||
Z3_ast Z3_API Z3_get_app_arg(Z3_context c, Z3_app a, unsigned i);
|
Z3_ast Z3_API Z3_get_app_arg(Z3_context c, Z3_app a, unsigned i);
|
||||||
|
@ -5376,7 +5413,7 @@ extern "C" {
|
||||||
|
|
||||||
def_API('Z3_model_eval', BOOL, (_in(CONTEXT), _in(MODEL), _in(AST), _in(BOOL), _out(AST)))
|
def_API('Z3_model_eval', BOOL, (_in(CONTEXT), _in(MODEL), _in(AST), _in(BOOL), _out(AST)))
|
||||||
*/
|
*/
|
||||||
Z3_bool Z3_API Z3_model_eval(Z3_context c, Z3_model m, Z3_ast t, bool model_completion, Z3_ast * v);
|
bool Z3_API Z3_model_eval(Z3_context c, Z3_model m, Z3_ast t, bool model_completion, Z3_ast * v);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
\brief Return the interpretation (i.e., assignment) of constant \c a in the model \c m.
|
\brief Return the interpretation (i.e., assignment) of constant \c a in the model \c m.
|
||||||
|
@ -5425,6 +5462,7 @@ extern "C" {
|
||||||
\pre i < Z3_model_get_num_consts(c, m)
|
\pre i < Z3_model_get_num_consts(c, m)
|
||||||
|
|
||||||
\sa Z3_model_eval
|
\sa Z3_model_eval
|
||||||
|
\sa Z3_model_get_num_consts
|
||||||
|
|
||||||
def_API('Z3_model_get_const_decl', FUNC_DECL, (_in(CONTEXT), _in(MODEL), _in(UINT)))
|
def_API('Z3_model_get_const_decl', FUNC_DECL, (_in(CONTEXT), _in(MODEL), _in(UINT)))
|
||||||
*/
|
*/
|
||||||
|
@ -5436,6 +5474,8 @@ extern "C" {
|
||||||
A function interpretation is represented as a finite map and an 'else' value.
|
A function interpretation is represented as a finite map and an 'else' value.
|
||||||
Each entry in the finite map represents the value of a function given a set of arguments.
|
Each entry in the finite map represents the value of a function given a set of arguments.
|
||||||
|
|
||||||
|
\sa Z3_model_get_func_decl
|
||||||
|
|
||||||
def_API('Z3_model_get_num_funcs', UINT, (_in(CONTEXT), _in(MODEL)))
|
def_API('Z3_model_get_num_funcs', UINT, (_in(CONTEXT), _in(MODEL)))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_model_get_num_funcs(Z3_context c, Z3_model m);
|
unsigned Z3_API Z3_model_get_num_funcs(Z3_context c, Z3_model m);
|
||||||
|
@ -5561,6 +5601,8 @@ extern "C" {
|
||||||
Each entry in the finite map represents the value of a function given a set of arguments.
|
Each entry in the finite map represents the value of a function given a set of arguments.
|
||||||
This procedure return the number of element in the finite map of \c f.
|
This procedure return the number of element in the finite map of \c f.
|
||||||
|
|
||||||
|
\sa Z3_func_interp_get_entry
|
||||||
|
|
||||||
def_API('Z3_func_interp_get_num_entries', UINT, (_in(CONTEXT), _in(FUNC_INTERP)))
|
def_API('Z3_func_interp_get_num_entries', UINT, (_in(CONTEXT), _in(FUNC_INTERP)))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_func_interp_get_num_entries(Z3_context c, Z3_func_interp f);
|
unsigned Z3_API Z3_func_interp_get_num_entries(Z3_context c, Z3_func_interp f);
|
||||||
|
@ -5649,6 +5691,7 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Return the number of arguments in a \c Z3_func_entry object.
|
\brief Return the number of arguments in a \c Z3_func_entry object.
|
||||||
|
|
||||||
|
\sa Z3_func_entry_get_arg
|
||||||
\sa Z3_func_interp_get_entry
|
\sa Z3_func_interp_get_entry
|
||||||
|
|
||||||
def_API('Z3_func_entry_get_num_args', UINT, (_in(CONTEXT), _in(FUNC_ENTRY)))
|
def_API('Z3_func_entry_get_num_args', UINT, (_in(CONTEXT), _in(FUNC_ENTRY)))
|
||||||
|
@ -5660,6 +5703,7 @@ extern "C" {
|
||||||
|
|
||||||
\pre i < Z3_func_entry_get_num_args(c, e)
|
\pre i < Z3_func_entry_get_num_args(c, e)
|
||||||
|
|
||||||
|
\sa Z3_func_entry_get_num_args
|
||||||
\sa Z3_func_interp_get_entry
|
\sa Z3_func_interp_get_entry
|
||||||
|
|
||||||
def_API('Z3_func_entry_get_arg', AST, (_in(CONTEXT), _in(FUNC_ENTRY), _in(UINT)))
|
def_API('Z3_func_entry_get_arg', AST, (_in(CONTEXT), _in(FUNC_ENTRY), _in(UINT)))
|
||||||
|
@ -5672,6 +5716,9 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Log interaction to a file.
|
\brief Log interaction to a file.
|
||||||
|
|
||||||
|
\sa Z3_append_log
|
||||||
|
\sa Z3_close_log
|
||||||
|
|
||||||
extra_API('Z3_open_log', INT, (_in(STRING),))
|
extra_API('Z3_open_log', INT, (_in(STRING),))
|
||||||
*/
|
*/
|
||||||
bool Z3_API Z3_open_log(Z3_string filename);
|
bool Z3_API Z3_open_log(Z3_string filename);
|
||||||
|
@ -5679,10 +5726,13 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Append user-defined string to interaction log.
|
\brief Append user-defined string to interaction log.
|
||||||
|
|
||||||
The interaction log is opened using Z3_open_log.
|
The interaction log is opened using #Z3_open_log.
|
||||||
It contains the formulas that are checked using Z3.
|
It contains the formulas that are checked using Z3.
|
||||||
You can use this command to append comments, for instance.
|
You can use this command to append comments, for instance.
|
||||||
|
|
||||||
|
\sa Z3_open_log
|
||||||
|
\sa Z3_close_log
|
||||||
|
|
||||||
extra_API('Z3_append_log', VOID, (_in(STRING),))
|
extra_API('Z3_append_log', VOID, (_in(STRING),))
|
||||||
*/
|
*/
|
||||||
void Z3_API Z3_append_log(Z3_string string);
|
void Z3_API Z3_append_log(Z3_string string);
|
||||||
|
@ -5690,6 +5740,9 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Close interaction log.
|
\brief Close interaction log.
|
||||||
|
|
||||||
|
\sa Z3_open_log
|
||||||
|
\sa Z3_append_log
|
||||||
|
|
||||||
extra_API('Z3_close_log', VOID, ())
|
extra_API('Z3_close_log', VOID, ())
|
||||||
*/
|
*/
|
||||||
void Z3_API Z3_close_log(void);
|
void Z3_API Z3_close_log(void);
|
||||||
|
@ -6388,6 +6441,8 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Return the number of builtin tactics available in Z3.
|
\brief Return the number of builtin tactics available in Z3.
|
||||||
|
|
||||||
|
\sa Z3_get_tactic_name
|
||||||
|
|
||||||
def_API('Z3_get_num_tactics', UINT, (_in(CONTEXT),))
|
def_API('Z3_get_num_tactics', UINT, (_in(CONTEXT),))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_get_num_tactics(Z3_context c);
|
unsigned Z3_API Z3_get_num_tactics(Z3_context c);
|
||||||
|
@ -6397,6 +6452,8 @@ extern "C" {
|
||||||
|
|
||||||
\pre i < Z3_get_num_tactics(c)
|
\pre i < Z3_get_num_tactics(c)
|
||||||
|
|
||||||
|
\sa Z3_get_num_tactics
|
||||||
|
|
||||||
def_API('Z3_get_tactic_name', STRING, (_in(CONTEXT), _in(UINT)))
|
def_API('Z3_get_tactic_name', STRING, (_in(CONTEXT), _in(UINT)))
|
||||||
*/
|
*/
|
||||||
Z3_string Z3_API Z3_get_tactic_name(Z3_context c, unsigned i);
|
Z3_string Z3_API Z3_get_tactic_name(Z3_context c, unsigned i);
|
||||||
|
@ -6404,6 +6461,8 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Return the number of builtin probes available in Z3.
|
\brief Return the number of builtin probes available in Z3.
|
||||||
|
|
||||||
|
\sa Z3_get_probe_name
|
||||||
|
|
||||||
def_API('Z3_get_num_probes', UINT, (_in(CONTEXT),))
|
def_API('Z3_get_num_probes', UINT, (_in(CONTEXT),))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_get_num_probes(Z3_context c);
|
unsigned Z3_API Z3_get_num_probes(Z3_context c);
|
||||||
|
@ -6413,6 +6472,8 @@ extern "C" {
|
||||||
|
|
||||||
\pre i < Z3_get_num_probes(c)
|
\pre i < Z3_get_num_probes(c)
|
||||||
|
|
||||||
|
\sa Z3_get_num_probes
|
||||||
|
|
||||||
def_API('Z3_get_probe_name', STRING, (_in(CONTEXT), _in(UINT)))
|
def_API('Z3_get_probe_name', STRING, (_in(CONTEXT), _in(UINT)))
|
||||||
*/
|
*/
|
||||||
Z3_string Z3_API Z3_get_probe_name(Z3_context c, unsigned i);
|
Z3_string Z3_API Z3_get_probe_name(Z3_context c, unsigned i);
|
||||||
|
@ -6456,6 +6517,8 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Apply tactic \c t to the goal \c g.
|
\brief Apply tactic \c t to the goal \c g.
|
||||||
|
|
||||||
|
\sa Z3_tactic_apply_ex
|
||||||
|
|
||||||
def_API('Z3_tactic_apply', APPLY_RESULT, (_in(CONTEXT), _in(TACTIC), _in(GOAL)))
|
def_API('Z3_tactic_apply', APPLY_RESULT, (_in(CONTEXT), _in(TACTIC), _in(GOAL)))
|
||||||
*/
|
*/
|
||||||
Z3_apply_result Z3_API Z3_tactic_apply(Z3_context c, Z3_tactic t, Z3_goal g);
|
Z3_apply_result Z3_API Z3_tactic_apply(Z3_context c, Z3_tactic t, Z3_goal g);
|
||||||
|
@ -6463,6 +6526,8 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Apply tactic \c t to the goal \c g using the parameter set \c p.
|
\brief Apply tactic \c t to the goal \c g using the parameter set \c p.
|
||||||
|
|
||||||
|
\sa Z3_tactic_apply
|
||||||
|
|
||||||
def_API('Z3_tactic_apply_ex', APPLY_RESULT, (_in(CONTEXT), _in(TACTIC), _in(GOAL), _in(PARAMS)))
|
def_API('Z3_tactic_apply_ex', APPLY_RESULT, (_in(CONTEXT), _in(TACTIC), _in(GOAL), _in(PARAMS)))
|
||||||
*/
|
*/
|
||||||
Z3_apply_result Z3_API Z3_tactic_apply_ex(Z3_context c, Z3_tactic t, Z3_goal g, Z3_params p);
|
Z3_apply_result Z3_API Z3_tactic_apply_ex(Z3_context c, Z3_tactic t, Z3_goal g, Z3_params p);
|
||||||
|
@ -6491,6 +6556,8 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
\brief Return the number of subgoals in the \c Z3_apply_result object returned by #Z3_tactic_apply.
|
\brief Return the number of subgoals in the \c Z3_apply_result object returned by #Z3_tactic_apply.
|
||||||
|
|
||||||
|
\sa Z3_apply_result_get_subgoal
|
||||||
|
|
||||||
def_API('Z3_apply_result_get_num_subgoals', UINT, (_in(CONTEXT), _in(APPLY_RESULT)))
|
def_API('Z3_apply_result_get_num_subgoals', UINT, (_in(CONTEXT), _in(APPLY_RESULT)))
|
||||||
*/
|
*/
|
||||||
unsigned Z3_API Z3_apply_result_get_num_subgoals(Z3_context c, Z3_apply_result r);
|
unsigned Z3_API Z3_apply_result_get_num_subgoals(Z3_context c, Z3_apply_result r);
|
||||||
|
@ -6500,6 +6567,8 @@ extern "C" {
|
||||||
|
|
||||||
\pre i < Z3_apply_result_get_num_subgoals(c, r)
|
\pre i < Z3_apply_result_get_num_subgoals(c, r)
|
||||||
|
|
||||||
|
\sa Z3_apply_result_get_num_subgoals
|
||||||
|
|
||||||
def_API('Z3_apply_result_get_subgoal', GOAL, (_in(CONTEXT), _in(APPLY_RESULT), _in(UINT)))
|
def_API('Z3_apply_result_get_subgoal', GOAL, (_in(CONTEXT), _in(APPLY_RESULT), _in(UINT)))
|
||||||
*/
|
*/
|
||||||
Z3_goal Z3_API Z3_apply_result_get_subgoal(Z3_context c, Z3_apply_result r, unsigned i);
|
Z3_goal Z3_API Z3_apply_result_get_subgoal(Z3_context c, Z3_apply_result r, unsigned i);
|
||||||
|
@ -6542,6 +6611,10 @@ extern "C" {
|
||||||
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
||||||
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
||||||
|
|
||||||
|
\sa Z3_mk_simple_solver
|
||||||
|
\sa Z3_mk_solver_for_logic
|
||||||
|
\sa Z3_mk_solver_from_tactic
|
||||||
|
|
||||||
def_API('Z3_mk_solver', SOLVER, (_in(CONTEXT),))
|
def_API('Z3_mk_solver', SOLVER, (_in(CONTEXT),))
|
||||||
*/
|
*/
|
||||||
Z3_solver Z3_API Z3_mk_solver(Z3_context c);
|
Z3_solver Z3_API Z3_mk_solver(Z3_context c);
|
||||||
|
@ -6569,6 +6642,10 @@ extern "C" {
|
||||||
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
||||||
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
||||||
|
|
||||||
|
\sa Z3_mk_solver
|
||||||
|
\sa Z3_mk_solver_for_logic
|
||||||
|
\sa Z3_mk_solver_from_tactic
|
||||||
|
|
||||||
def_API('Z3_mk_simple_solver', SOLVER, (_in(CONTEXT),))
|
def_API('Z3_mk_simple_solver', SOLVER, (_in(CONTEXT),))
|
||||||
*/
|
*/
|
||||||
Z3_solver Z3_API Z3_mk_simple_solver(Z3_context c);
|
Z3_solver Z3_API Z3_mk_simple_solver(Z3_context c);
|
||||||
|
@ -6580,6 +6657,10 @@ extern "C" {
|
||||||
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
||||||
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
||||||
|
|
||||||
|
\sa Z3_mk_solver
|
||||||
|
\sa Z3_mk_simple_solver
|
||||||
|
\sa Z3_mk_solver_from_tactic
|
||||||
|
|
||||||
def_API('Z3_mk_solver_for_logic', SOLVER, (_in(CONTEXT), _in(SYMBOL)))
|
def_API('Z3_mk_solver_for_logic', SOLVER, (_in(CONTEXT), _in(SYMBOL)))
|
||||||
*/
|
*/
|
||||||
Z3_solver Z3_API Z3_mk_solver_for_logic(Z3_context c, Z3_symbol logic);
|
Z3_solver Z3_API Z3_mk_solver_for_logic(Z3_context c, Z3_symbol logic);
|
||||||
|
@ -6592,6 +6673,10 @@ extern "C" {
|
||||||
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
\remark User must use #Z3_solver_inc_ref and #Z3_solver_dec_ref to manage solver objects.
|
||||||
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
Even if the context was created using #Z3_mk_context instead of #Z3_mk_context_rc.
|
||||||
|
|
||||||
|
\sa Z3_mk_solver
|
||||||
|
\sa Z3_mk_simple_solver
|
||||||
|
\sa Z3_mk_solver_for_logic
|
||||||
|
|
||||||
def_API('Z3_mk_solver_from_tactic', SOLVER, (_in(CONTEXT), _in(TACTIC)))
|
def_API('Z3_mk_solver_from_tactic', SOLVER, (_in(CONTEXT), _in(TACTIC)))
|
||||||
*/
|
*/
|
||||||
Z3_solver Z3_API Z3_mk_solver_from_tactic(Z3_context c, Z3_tactic t);
|
Z3_solver Z3_API Z3_mk_solver_from_tactic(Z3_context c, Z3_tactic t);
|
||||||
|
@ -6899,7 +6984,7 @@ extern "C" {
|
||||||
/**
|
/**
|
||||||
Create uninterpreted function declaration for the user propagator.
|
Create uninterpreted function declaration for the user propagator.
|
||||||
When expressions using the function are created by the solver invoke a callback
|
When expressions using the function are created by the solver invoke a callback
|
||||||
to \ref \Z3_solver_propagate_created with arguments
|
to \ref Z3_solver_propagate_created with arguments
|
||||||
1. context and callback solve
|
1. context and callback solve
|
||||||
2. declared_expr: expression using function that was used as the top-level symbol
|
2. declared_expr: expression using function that was used as the top-level symbol
|
||||||
3. declared_id: a unique identifier (unique within the current scope) to track the expression.
|
3. declared_id: a unique identifier (unique within the current scope) to track the expression.
|
||||||
|
|
|
@ -16,6 +16,8 @@ Author:
|
||||||
Notes:
|
Notes:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/symbol.h"
|
#include "util/symbol.h"
|
||||||
|
|
||||||
void R();
|
void R();
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
Copyright (c) 2015 Microsoft Corporation
|
Copyright (c) 2015 Microsoft Corporation
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#ifndef Z3_API
|
#ifndef Z3_API
|
||||||
# ifdef __GNUC__
|
# ifdef __GNUC__
|
||||||
|
|
|
@ -107,7 +107,6 @@ class array_decl_plugin : public decl_plugin {
|
||||||
bool is_array_sort(sort* s) const;
|
bool is_array_sort(sort* s) const;
|
||||||
public:
|
public:
|
||||||
array_decl_plugin();
|
array_decl_plugin();
|
||||||
~array_decl_plugin() override {}
|
|
||||||
|
|
||||||
decl_plugin * mk_fresh() override {
|
decl_plugin * mk_fresh() override {
|
||||||
return alloc(array_decl_plugin);
|
return alloc(array_decl_plugin);
|
||||||
|
|
|
@ -1429,7 +1429,7 @@ ast_manager::~ast_manager() {
|
||||||
}
|
}
|
||||||
m_plugins.reset();
|
m_plugins.reset();
|
||||||
while (!m_ast_table.empty()) {
|
while (!m_ast_table.empty()) {
|
||||||
DEBUG_CODE(IF_VERBOSE(0, verbose_stream() << "ast_manager LEAKED: " << m_ast_table.size() << std::endl););
|
DEBUG_CODE(IF_VERBOSE(1, verbose_stream() << "ast_manager LEAKED: " << m_ast_table.size() << std::endl););
|
||||||
ptr_vector<ast> roots;
|
ptr_vector<ast> roots;
|
||||||
ast_mark mark;
|
ast_mark mark;
|
||||||
for (ast * n : m_ast_table) {
|
for (ast * n : m_ast_table) {
|
||||||
|
@ -1465,22 +1465,21 @@ ast_manager::~ast_manager() {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (ast * n : m_ast_table) {
|
for (ast * n : m_ast_table)
|
||||||
if (!mark.is_marked(n)) {
|
if (!mark.is_marked(n))
|
||||||
roots.push_back(n);
|
roots.push_back(n);
|
||||||
}
|
|
||||||
}
|
|
||||||
SASSERT(!roots.empty());
|
SASSERT(!roots.empty());
|
||||||
for (unsigned i = 0; i < roots.size(); ++i) {
|
for (unsigned i = 0; i < roots.size(); ++i) {
|
||||||
ast* a = roots[i];
|
ast* a = roots[i];
|
||||||
DEBUG_CODE(
|
DEBUG_CODE(
|
||||||
std::cout << "Leaked: ";
|
IF_VERBOSE(1,
|
||||||
if (is_sort(a)) {
|
verbose_stream() << "Leaked: ";
|
||||||
std::cout << to_sort(a)->get_name() << "\n";
|
if (is_sort(a))
|
||||||
}
|
verbose_stream() << to_sort(a)->get_name() << "\n";
|
||||||
else {
|
else
|
||||||
std::cout << mk_ll_pp(a, *this, false) << "id: " << a->get_id() << "\n";
|
verbose_stream() << mk_ll_pp(a, *this, false) << "id: " << a->get_id() << "\n";
|
||||||
});
|
););
|
||||||
a->m_ref_count = 0;
|
a->m_ref_count = 0;
|
||||||
delete_node(a);
|
delete_node(a);
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,6 @@ class simple_ast_printer_context : public ast_printer_context {
|
||||||
smt2_pp_environment_dbg & env() const { return *(m_env.get()); }
|
smt2_pp_environment_dbg & env() const { return *(m_env.get()); }
|
||||||
public:
|
public:
|
||||||
simple_ast_printer_context(ast_manager & m):m_manager(m) { m_env = alloc(smt2_pp_environment_dbg, m); }
|
simple_ast_printer_context(ast_manager & m):m_manager(m) { m_env = alloc(smt2_pp_environment_dbg, m); }
|
||||||
~simple_ast_printer_context() override {}
|
|
||||||
ast_manager & m() const { return m_manager; }
|
ast_manager & m() const { return m_manager; }
|
||||||
ast_manager & get_ast_manager() override { return m_manager; }
|
ast_manager & get_ast_manager() override { return m_manager; }
|
||||||
void display(std::ostream & out, sort * s, unsigned indent = 0) const override { out << mk_ismt2_pp(s, m(), indent); }
|
void display(std::ostream & out, sort * s, unsigned indent = 0) const override { out << mk_ismt2_pp(s, m(), indent); }
|
||||||
|
|
|
@ -45,7 +45,6 @@ public:
|
||||||
|
|
||||||
class ast_printer_context : public ast_printer {
|
class ast_printer_context : public ast_printer {
|
||||||
public:
|
public:
|
||||||
~ast_printer_context() override {}
|
|
||||||
virtual ast_manager & get_ast_manager() = 0;
|
virtual ast_manager & get_ast_manager() = 0;
|
||||||
virtual std::ostream & regular_stream();
|
virtual std::ostream & regular_stream();
|
||||||
virtual std::ostream & diagnostic_stream();
|
virtual std::ostream & diagnostic_stream();
|
||||||
|
|
|
@ -241,7 +241,6 @@ protected:
|
||||||
public:
|
public:
|
||||||
bv_decl_plugin();
|
bv_decl_plugin();
|
||||||
|
|
||||||
~bv_decl_plugin() override {}
|
|
||||||
void finalize() override;
|
void finalize() override;
|
||||||
|
|
||||||
decl_plugin * mk_fresh() override { return alloc(bv_decl_plugin); }
|
decl_plugin * mk_fresh() override { return alloc(bv_decl_plugin); }
|
||||||
|
|
|
@ -101,7 +101,6 @@ namespace datalog {
|
||||||
public:
|
public:
|
||||||
|
|
||||||
dl_decl_plugin();
|
dl_decl_plugin();
|
||||||
~dl_decl_plugin() override {}
|
|
||||||
|
|
||||||
decl_plugin * mk_fresh() override { return alloc(dl_decl_plugin); }
|
decl_plugin * mk_fresh() override { return alloc(dl_decl_plugin); }
|
||||||
|
|
||||||
|
|
|
@ -52,8 +52,6 @@ namespace format_ns {
|
||||||
m_line_break_ext("cr++") {
|
m_line_break_ext("cr++") {
|
||||||
}
|
}
|
||||||
|
|
||||||
~format_decl_plugin() override {}
|
|
||||||
|
|
||||||
void finalize() override {
|
void finalize() override {
|
||||||
if (m_format_sort)
|
if (m_format_sort)
|
||||||
m_manager->dec_ref(m_format_sort);
|
m_manager->dec_ref(m_format_sort);
|
||||||
|
|
|
@ -239,7 +239,6 @@ class fpa2bv_converter_wrapped : public fpa2bv_converter {
|
||||||
fpa2bv_converter_wrapped(ast_manager & m, th_rewriter& rw) :
|
fpa2bv_converter_wrapped(ast_manager & m, th_rewriter& rw) :
|
||||||
fpa2bv_converter(m),
|
fpa2bv_converter(m),
|
||||||
m_rw(rw) {}
|
m_rw(rw) {}
|
||||||
virtual ~fpa2bv_converter_wrapped() {}
|
|
||||||
void mk_const(func_decl * f, expr_ref & result) override;
|
void mk_const(func_decl * f, expr_ref & result) override;
|
||||||
void mk_rm_const(func_decl * f, expr_ref & result) override;
|
void mk_rm_const(func_decl * f, expr_ref & result) override;
|
||||||
app_ref wrap(expr * e);
|
app_ref wrap(expr * e);
|
||||||
|
|
|
@ -77,9 +77,6 @@ public:
|
||||||
m_rw(m, m.proofs_enabled(), m_cfg) {
|
m_rw(m, m.proofs_enabled(), m_cfg) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~name_exprs_core() override {
|
|
||||||
}
|
|
||||||
|
|
||||||
void operator()(expr * n, expr_ref_vector & new_defs, proof_ref_vector & new_def_proofs, expr_ref & r, proof_ref & p) override {
|
void operator()(expr * n, expr_ref_vector & new_defs, proof_ref_vector & new_def_proofs, expr_ref & r, proof_ref & p) override {
|
||||||
m_cfg.m_def_exprs = &new_defs;
|
m_cfg.m_def_exprs = &new_defs;
|
||||||
m_cfg.m_def_proofs = &new_def_proofs;
|
m_cfg.m_def_proofs = &new_def_proofs;
|
||||||
|
@ -113,9 +110,6 @@ public:
|
||||||
name_exprs_core(m, n, m_pred),
|
name_exprs_core(m, n, m_pred),
|
||||||
m_pred(m) {
|
m_pred(m) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~name_quantifier_labels() override {
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
name_exprs * mk_quantifier_label_namer(ast_manager & m, defined_names & n) {
|
name_exprs * mk_quantifier_label_namer(ast_manager & m, defined_names & n) {
|
||||||
|
@ -145,9 +139,6 @@ public:
|
||||||
m_pred(m) {
|
m_pred(m) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~name_nested_formulas() override {
|
|
||||||
}
|
|
||||||
|
|
||||||
void operator()(expr * n, expr_ref_vector & new_defs, proof_ref_vector & new_def_proofs, expr_ref & r, proof_ref & p) override {
|
void operator()(expr * n, expr_ref_vector & new_defs, proof_ref_vector & new_def_proofs, expr_ref & r, proof_ref & p) override {
|
||||||
m_pred.m_root = n;
|
m_pred.m_root = n;
|
||||||
TRACE("name_exprs", tout << "operator()\n";);
|
TRACE("name_exprs", tout << "operator()\n";);
|
||||||
|
|
|
@ -52,7 +52,6 @@ class pb_decl_plugin : public decl_plugin {
|
||||||
func_decl * mk_eq(unsigned arity, rational const* coeffs, int k);
|
func_decl * mk_eq(unsigned arity, rational const* coeffs, int k);
|
||||||
public:
|
public:
|
||||||
pb_decl_plugin();
|
pb_decl_plugin();
|
||||||
~pb_decl_plugin() override {}
|
|
||||||
|
|
||||||
sort * mk_sort(decl_kind k, unsigned num_parameters, parameter const * parameters) override {
|
sort * mk_sort(decl_kind k, unsigned num_parameters, parameter const * parameters) override {
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
|
|
|
@ -52,8 +52,6 @@ class proof_checker {
|
||||||
public:
|
public:
|
||||||
hyp_decl_plugin();
|
hyp_decl_plugin();
|
||||||
|
|
||||||
~hyp_decl_plugin() override {}
|
|
||||||
|
|
||||||
void finalize() override;
|
void finalize() override;
|
||||||
|
|
||||||
decl_plugin * mk_fresh() override { return alloc(hyp_decl_plugin); }
|
decl_plugin * mk_fresh() override { return alloc(hyp_decl_plugin); }
|
||||||
|
|
|
@ -16,6 +16,8 @@ Author:
|
||||||
Revision History:
|
Revision History:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/rational.h"
|
#include "util/rational.h"
|
||||||
#include "util/common_msgs.h"
|
#include "util/common_msgs.h"
|
||||||
#include "ast/rewriter/bit_blaster/bit_blaster_tpl.h"
|
#include "ast/rewriter/bit_blaster/bit_blaster_tpl.h"
|
||||||
|
|
|
@ -68,8 +68,6 @@ public:
|
||||||
rewriter_tpl<elim_bounds_cfg>(m, m.proofs_enabled(), m_cfg),
|
rewriter_tpl<elim_bounds_cfg>(m, m.proofs_enabled(), m_cfg),
|
||||||
m_cfg(m)
|
m_cfg(m)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
~elim_bounds_rw() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -129,8 +129,6 @@ public:
|
||||||
m_r(m, p) {
|
m_r(m, p) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~th_rewriter2expr_replacer() override {}
|
|
||||||
|
|
||||||
ast_manager & m() const override { return m_r.m(); }
|
ast_manager & m() const override { return m_r.m(); }
|
||||||
|
|
||||||
void set_substitution(expr_substitution * s) override { m_r.set_substitution(s); }
|
void set_substitution(expr_substitution * s) override { m_r.set_substitution(s); }
|
||||||
|
|
|
@ -16,6 +16,7 @@ Author:
|
||||||
Notes:
|
Notes:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/container_util.h"
|
#include "util/container_util.h"
|
||||||
#include "ast/rewriter/poly_rewriter.h"
|
#include "ast/rewriter/poly_rewriter.h"
|
||||||
|
|
|
@ -49,7 +49,6 @@ protected:
|
||||||
bool is_target(func_decl * decl, unsigned num_args, expr * const * args) override;
|
bool is_target(func_decl * decl, unsigned num_args, expr * const * args) override;
|
||||||
public:
|
public:
|
||||||
ng_push_app_ite_cfg(ast_manager& m): push_app_ite_cfg(m) {}
|
ng_push_app_ite_cfg(ast_manager& m): push_app_ite_cfg(m) {}
|
||||||
virtual ~ng_push_app_ite_cfg() {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct push_app_ite_rw : public rewriter_tpl<push_app_ite_cfg> {
|
struct push_app_ite_rw : public rewriter_tpl<push_app_ite_cfg> {
|
||||||
|
|
|
@ -32,7 +32,6 @@ class recfun_replace : public recfun::replace {
|
||||||
expr_safe_replace m_replace;
|
expr_safe_replace m_replace;
|
||||||
public:
|
public:
|
||||||
recfun_replace(ast_manager& m): m(m), m_replace(m) {}
|
recfun_replace(ast_manager& m): m(m), m_replace(m) {}
|
||||||
~recfun_replace() override {}
|
|
||||||
void reset() override { m_replace.reset(); }
|
void reset() override { m_replace.reset(); }
|
||||||
void insert(expr* s, expr* t) override { m_replace.insert(s, t); }
|
void insert(expr* s, expr* t) override { m_replace.insert(s, t); }
|
||||||
expr_ref operator()(expr* e) override { expr_ref r(m); m_replace(e, r); return r; }
|
expr_ref operator()(expr* e) override { expr_ref r(m); m_replace(e, r); return r; }
|
||||||
|
|
|
@ -16,6 +16,8 @@ Author:
|
||||||
Notes:
|
Notes:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "ast/rewriter/rewriter.h"
|
#include "ast/rewriter/rewriter.h"
|
||||||
#include "ast/ast_smt2_pp.h"
|
#include "ast/ast_smt2_pp.h"
|
||||||
#include "ast/ast_ll_pp.h"
|
#include "ast/ast_ll_pp.h"
|
||||||
|
|
|
@ -1107,6 +1107,31 @@ unsigned seq_util::rex::max_length(expr* r) const {
|
||||||
return UINT_MAX;
|
return UINT_MAX;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
\brief determine if \c n is a range regular expression where the lower and upper bounds
|
||||||
|
are given by single characters.
|
||||||
|
Range expressions where lower and upper bounds are not single characters are either
|
||||||
|
the empty language (when a bound is a string but not a single character) or symbolic
|
||||||
|
(when both bounds are not ground strings). The general is_range can be used to process
|
||||||
|
range expressions for these cases, but they don't correspond to mainstream regex usage.
|
||||||
|
*/
|
||||||
|
bool seq_util::rex::is_range(expr const* n, unsigned& lo, unsigned& hi) const {
|
||||||
|
expr* _lo, *_hi;
|
||||||
|
zstring los, his;
|
||||||
|
if (!is_range(n, _lo, _hi))
|
||||||
|
return false;
|
||||||
|
if (!u.str.is_string(_lo, los))
|
||||||
|
return false;
|
||||||
|
if (!u.str.is_string(_hi, his))
|
||||||
|
return false;
|
||||||
|
if (los.length() != 1 || his.length() != 1)
|
||||||
|
return false;
|
||||||
|
lo = los[0];
|
||||||
|
hi = his[0];
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
sort* seq_util::rex::to_seq(sort* re) {
|
sort* seq_util::rex::to_seq(sort* re) {
|
||||||
(void)u;
|
(void)u;
|
||||||
SASSERT(u.is_re(re));
|
SASSERT(u.is_re(re));
|
||||||
|
|
|
@ -545,6 +545,7 @@ public:
|
||||||
bool is_plus(expr const* n) const { return is_app_of(n, m_fid, OP_RE_PLUS); }
|
bool is_plus(expr const* n) const { return is_app_of(n, m_fid, OP_RE_PLUS); }
|
||||||
bool is_opt(expr const* n) const { return is_app_of(n, m_fid, OP_RE_OPTION); }
|
bool is_opt(expr const* n) const { return is_app_of(n, m_fid, OP_RE_OPTION); }
|
||||||
bool is_range(expr const* n) const { return is_app_of(n, m_fid, OP_RE_RANGE); }
|
bool is_range(expr const* n) const { return is_app_of(n, m_fid, OP_RE_RANGE); }
|
||||||
|
bool is_range(expr const* n, unsigned& lo, unsigned& hi) const;
|
||||||
bool is_loop(expr const* n) const { return is_app_of(n, m_fid, OP_RE_LOOP); }
|
bool is_loop(expr const* n) const { return is_app_of(n, m_fid, OP_RE_LOOP); }
|
||||||
bool is_empty(expr const* n) const { return is_app_of(n, m_fid, OP_RE_EMPTY_SET); }
|
bool is_empty(expr const* n) const { return is_app_of(n, m_fid, OP_RE_EMPTY_SET); }
|
||||||
bool is_full_char(expr const* n) const { return is_app_of(n, m_fid, OP_RE_FULL_CHAR_SET); }
|
bool is_full_char(expr const* n) const { return is_app_of(n, m_fid, OP_RE_FULL_CHAR_SET); }
|
||||||
|
|
|
@ -40,8 +40,6 @@ class special_relations_decl_plugin : public decl_plugin {
|
||||||
public:
|
public:
|
||||||
special_relations_decl_plugin();
|
special_relations_decl_plugin();
|
||||||
|
|
||||||
~special_relations_decl_plugin() override {}
|
|
||||||
|
|
||||||
decl_plugin * mk_fresh() override {
|
decl_plugin * mk_fresh() override {
|
||||||
return alloc(special_relations_decl_plugin);
|
return alloc(special_relations_decl_plugin);
|
||||||
}
|
}
|
||||||
|
|
|
@ -99,7 +99,7 @@ public:
|
||||||
datatype_value_generator(value_generator& g, ast_manager& m):
|
datatype_value_generator(value_generator& g, ast_manager& m):
|
||||||
m(m), g(g), dt(m), m_sorts(m) {}
|
m(m), g(g), dt(m), m_sorts(m) {}
|
||||||
|
|
||||||
~datatype_value_generator() {
|
~datatype_value_generator() override {
|
||||||
for (auto& kv : m_values) dealloc(kv.m_value);
|
for (auto& kv : m_values) dealloc(kv.m_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -379,8 +379,6 @@ public:
|
||||||
m_int_real_coercions(":int-real-coercions"),
|
m_int_real_coercions(":int-real-coercions"),
|
||||||
m_reproducible_resource_limit(":reproducible-resource-limit") {
|
m_reproducible_resource_limit(":reproducible-resource-limit") {
|
||||||
}
|
}
|
||||||
~set_get_option_cmd() override {}
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class set_option_cmd : public set_get_option_cmd {
|
class set_option_cmd : public set_get_option_cmd {
|
||||||
|
|
|
@ -493,7 +493,6 @@ protected:
|
||||||
|
|
||||||
public:
|
public:
|
||||||
pp_env(cmd_context & o):m_owner(o), m_autil(o.m()), m_bvutil(o.m()), m_arutil(o.m()), m_futil(o.m()), m_sutil(o.m()), m_dtutil(o.m()), m_dlutil(o.m()) {}
|
pp_env(cmd_context & o):m_owner(o), m_autil(o.m()), m_bvutil(o.m()), m_arutil(o.m()), m_futil(o.m()), m_sutil(o.m()), m_dtutil(o.m()), m_dlutil(o.m()) {}
|
||||||
~pp_env() override {}
|
|
||||||
ast_manager & get_manager() const override { return m_owner.m(); }
|
ast_manager & get_manager() const override { return m_owner.m(); }
|
||||||
arith_util & get_autil() override { return m_autil; }
|
arith_util & get_autil() override { return m_autil; }
|
||||||
bv_util & get_bvutil() override { return m_bvutil; }
|
bv_util & get_bvutil() override { return m_bvutil; }
|
||||||
|
|
|
@ -15,6 +15,7 @@ Author:
|
||||||
Notes:
|
Notes:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
class cmd_context;
|
class cmd_context;
|
||||||
|
|
||||||
|
|
|
@ -147,7 +147,6 @@ class psort_sort : public psort {
|
||||||
sort * get_sort() const { return m_sort; }
|
sort * get_sort() const { return m_sort; }
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override { return m_sort; }
|
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override { return m_sort; }
|
||||||
public:
|
public:
|
||||||
~psort_sort() override {}
|
|
||||||
bool is_sort_wrapper() const override { return true; }
|
bool is_sort_wrapper() const override { return true; }
|
||||||
char const * hcons_kind() const override { return "psort_sort"; }
|
char const * hcons_kind() const override { return "psort_sort"; }
|
||||||
unsigned hcons_hash() const override { return m_sort->get_id(); }
|
unsigned hcons_hash() const override { return m_sort->get_id(); }
|
||||||
|
@ -171,7 +170,6 @@ class psort_var : public psort {
|
||||||
}
|
}
|
||||||
size_t obj_size() const override { return sizeof(psort_var); }
|
size_t obj_size() const override { return sizeof(psort_var); }
|
||||||
public:
|
public:
|
||||||
~psort_var() override {}
|
|
||||||
char const * hcons_kind() const override { return "psort_var"; }
|
char const * hcons_kind() const override { return "psort_var"; }
|
||||||
unsigned hcons_hash() const override { return hash_u_u(m_num_params, m_idx); }
|
unsigned hcons_hash() const override { return hash_u_u(m_num_params, m_idx); }
|
||||||
bool hcons_eq(psort const * other) const override {
|
bool hcons_eq(psort const * other) const override {
|
||||||
|
@ -233,7 +231,6 @@ class psort_app : public psort {
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
~psort_app() override {}
|
|
||||||
char const * hcons_kind() const override { return "psort_app"; }
|
char const * hcons_kind() const override { return "psort_app"; }
|
||||||
unsigned hcons_hash() const override {
|
unsigned hcons_hash() const override {
|
||||||
return get_composite_hash<psort_app*, khasher, chasher>(const_cast<psort_app*>(this), m_args.size());
|
return get_composite_hash<psort_app*, khasher, chasher>(const_cast<psort_app*>(this), m_args.size());
|
||||||
|
@ -800,8 +797,6 @@ struct pdecl_manager::app_sort_info : public pdecl_manager::sort_info {
|
||||||
m.m().inc_array_ref(n, s);
|
m.m().inc_array_ref(n, s);
|
||||||
}
|
}
|
||||||
|
|
||||||
~app_sort_info() override {}
|
|
||||||
|
|
||||||
unsigned obj_size() const override { return sizeof(app_sort_info); }
|
unsigned obj_size() const override { return sizeof(app_sort_info); }
|
||||||
|
|
||||||
void finalize(pdecl_manager & m) override {
|
void finalize(pdecl_manager & m) override {
|
||||||
|
@ -843,8 +838,6 @@ struct pdecl_manager::indexed_sort_info : public pdecl_manager::sort_info {
|
||||||
m_indices(n, s) {
|
m_indices(n, s) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~indexed_sort_info() override {}
|
|
||||||
|
|
||||||
unsigned obj_size() const override { return sizeof(indexed_sort_info); }
|
unsigned obj_size() const override { return sizeof(indexed_sort_info); }
|
||||||
|
|
||||||
void display(std::ostream & out, pdecl_manager const & m) const override {
|
void display(std::ostream & out, pdecl_manager const & m) const override {
|
||||||
|
|
|
@ -66,7 +66,6 @@ protected:
|
||||||
psort(unsigned id, unsigned num_params):pdecl(id, num_params), m_inst_cache(nullptr) {}
|
psort(unsigned id, unsigned num_params):pdecl(id, num_params), m_inst_cache(nullptr) {}
|
||||||
bool is_psort() const override { return true; }
|
bool is_psort() const override { return true; }
|
||||||
void finalize(pdecl_manager & m) override;
|
void finalize(pdecl_manager & m) override;
|
||||||
~psort() override {}
|
|
||||||
virtual void cache(pdecl_manager & m, sort * const * s, sort * r);
|
virtual void cache(pdecl_manager & m, sort * const * s, sort * r);
|
||||||
virtual sort * find(sort * const * s) const;
|
virtual sort * find(sort * const * s) const;
|
||||||
public:
|
public:
|
||||||
|
@ -98,7 +97,6 @@ protected:
|
||||||
sort * find(sort * const * s);
|
sort * find(sort * const * s);
|
||||||
psort_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n);
|
psort_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n);
|
||||||
void finalize(pdecl_manager & m) override;
|
void finalize(pdecl_manager & m) override;
|
||||||
~psort_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
virtual sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) = 0;
|
virtual sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) = 0;
|
||||||
virtual sort * instantiate(pdecl_manager & m, unsigned n, unsigned const * s) { return nullptr; }
|
virtual sort * instantiate(pdecl_manager & m, unsigned n, unsigned const * s) { return nullptr; }
|
||||||
|
@ -120,7 +118,6 @@ protected:
|
||||||
psort_user_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n, psort * p);
|
psort_user_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n, psort * p);
|
||||||
size_t obj_size() const override { return sizeof(psort_user_decl); }
|
size_t obj_size() const override { return sizeof(psort_user_decl); }
|
||||||
void finalize(pdecl_manager & m) override;
|
void finalize(pdecl_manager & m) override;
|
||||||
~psort_user_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
||||||
std::ostream& display(std::ostream & out) const override;
|
std::ostream& display(std::ostream & out) const override;
|
||||||
|
@ -133,7 +130,6 @@ protected:
|
||||||
decl_kind m_kind;
|
decl_kind m_kind;
|
||||||
psort_builtin_decl(unsigned id, pdecl_manager & m, symbol const & n, family_id fid, decl_kind k);
|
psort_builtin_decl(unsigned id, pdecl_manager & m, symbol const & n, family_id fid, decl_kind k);
|
||||||
size_t obj_size() const override { return sizeof(psort_builtin_decl); }
|
size_t obj_size() const override { return sizeof(psort_builtin_decl); }
|
||||||
~psort_builtin_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, unsigned const * s) override;
|
sort * instantiate(pdecl_manager & m, unsigned n, unsigned const * s) override;
|
||||||
|
@ -145,7 +141,6 @@ protected:
|
||||||
friend class pdecl_manager;
|
friend class pdecl_manager;
|
||||||
psort_dt_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n);
|
psort_dt_decl(unsigned id, unsigned num_params, pdecl_manager & m, symbol const & n);
|
||||||
size_t obj_size() const override { return sizeof(psort_dt_decl); }
|
size_t obj_size() const override { return sizeof(psort_dt_decl); }
|
||||||
~psort_dt_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
||||||
std::ostream& display(std::ostream & out) const override;
|
std::ostream& display(std::ostream & out) const override;
|
||||||
|
@ -196,7 +191,6 @@ class paccessor_decl : public pdecl {
|
||||||
accessor_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
accessor_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
||||||
symbol const & get_name() const { return m_name; }
|
symbol const & get_name() const { return m_name; }
|
||||||
ptype const & get_type() const { return m_type; }
|
ptype const & get_type() const { return m_type; }
|
||||||
~paccessor_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
std::ostream& display(std::ostream & out) const override { pdecl::display(out); return out; }
|
std::ostream& display(std::ostream & out) const override { pdecl::display(out); return out; }
|
||||||
void display(std::ostream & out, pdatatype_decl const * const * dts) const;
|
void display(std::ostream & out, pdatatype_decl const * const * dts) const;
|
||||||
|
@ -217,7 +211,6 @@ class pconstructor_decl : public pdecl {
|
||||||
symbol const & get_name() const { return m_name; }
|
symbol const & get_name() const { return m_name; }
|
||||||
symbol const & get_recognizer_name() const { return m_recogniser_name; }
|
symbol const & get_recognizer_name() const { return m_recogniser_name; }
|
||||||
constructor_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
constructor_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
||||||
~pconstructor_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
std::ostream& display(std::ostream & out) const override { pdecl::display(out); return out; }
|
std::ostream& display(std::ostream & out) const override { pdecl::display(out); return out; }
|
||||||
void display(std::ostream & out, pdatatype_decl const * const * dts) const;
|
void display(std::ostream & out, pdatatype_decl const * const * dts) const;
|
||||||
|
@ -234,7 +227,6 @@ class pdatatype_decl : public psort_decl {
|
||||||
size_t obj_size() const override { return sizeof(pdatatype_decl); }
|
size_t obj_size() const override { return sizeof(pdatatype_decl); }
|
||||||
bool fix_missing_refs(dictionary<int> const & symbol2idx, symbol & missing);
|
bool fix_missing_refs(dictionary<int> const & symbol2idx, symbol & missing);
|
||||||
datatype_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
datatype_decl * instantiate_decl(pdecl_manager & m, unsigned n, sort * const * s);
|
||||||
~pdatatype_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
sort * instantiate(pdecl_manager & m, unsigned n, sort * const * s) override;
|
||||||
std::ostream& display(std::ostream & out) const override;
|
std::ostream& display(std::ostream & out) const override;
|
||||||
|
@ -255,7 +247,6 @@ class pdatatypes_decl : public pdecl {
|
||||||
size_t obj_size() const override { return sizeof(pdatatypes_decl); }
|
size_t obj_size() const override { return sizeof(pdatatypes_decl); }
|
||||||
bool fix_missing_refs(symbol & missing);
|
bool fix_missing_refs(symbol & missing);
|
||||||
bool instantiate(pdecl_manager & m, sort * const * s);
|
bool instantiate(pdecl_manager & m, sort * const * s);
|
||||||
~pdatatypes_decl() override {}
|
|
||||||
public:
|
public:
|
||||||
pdatatype_decl const * const * children() const { return m_datatypes.data(); }
|
pdatatype_decl const * const * children() const { return m_datatypes.data(); }
|
||||||
pdatatype_decl * const * begin() const { return m_datatypes.begin(); }
|
pdatatype_decl * const * begin() const { return m_datatypes.begin(); }
|
||||||
|
|
|
@ -46,10 +46,7 @@ public:
|
||||||
p.insert("print_proofs", CPK_BOOL, "(default: false) print a proof showing the original term is equal to the resultant one.");
|
p.insert("print_proofs", CPK_BOOL, "(default: false) print a proof showing the original term is equal to the resultant one.");
|
||||||
p.insert("print_statistics", CPK_BOOL, "(default: false) print statistics.");
|
p.insert("print_statistics", CPK_BOOL, "(default: false) print statistics.");
|
||||||
}
|
}
|
||||||
|
|
||||||
~simplify_cmd() override {
|
|
||||||
}
|
|
||||||
|
|
||||||
void prepare(cmd_context & ctx) override {
|
void prepare(cmd_context & ctx) override {
|
||||||
parametric_cmd::prepare(ctx);
|
parametric_cmd::prepare(ctx);
|
||||||
m_target = nullptr;
|
m_target = nullptr;
|
||||||
|
|
|
@ -38,7 +38,6 @@ public:
|
||||||
template<class T>
|
template<class T>
|
||||||
class boolean_algebra : public positive_boolean_algebra<T> {
|
class boolean_algebra : public positive_boolean_algebra<T> {
|
||||||
public:
|
public:
|
||||||
~boolean_algebra() override {}
|
|
||||||
virtual T mk_not(T x) = 0;
|
virtual T mk_not(T x) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -17,6 +17,8 @@ Author:
|
||||||
Revision History:
|
Revision History:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/dd/dd_pdd.h"
|
#include "math/dd/dd_pdd.h"
|
||||||
|
|
||||||
namespace dd {
|
namespace dd {
|
||||||
|
|
|
@ -17,6 +17,8 @@ Author:
|
||||||
Revision History:
|
Revision History:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/dd/dd_pdd.h"
|
#include "math/dd/dd_pdd.h"
|
||||||
#include "math/interval/dep_intervals.h"
|
#include "math/interval/dep_intervals.h"
|
||||||
|
|
||||||
|
|
|
@ -80,7 +80,6 @@ class heap_trie {
|
||||||
Value m_value;
|
Value m_value;
|
||||||
public:
|
public:
|
||||||
leaf(): node(leaf_t) {}
|
leaf(): node(leaf_t) {}
|
||||||
~leaf() override {}
|
|
||||||
Value const& get_value() const { return m_value; }
|
Value const& get_value() const { return m_value; }
|
||||||
void set_value(Value const& v) { m_value = v; }
|
void set_value(Value const& v) { m_value = v; }
|
||||||
void display(std::ostream& out, unsigned indent) const override {
|
void display(std::ostream& out, unsigned indent) const override {
|
||||||
|
@ -98,9 +97,6 @@ class heap_trie {
|
||||||
public:
|
public:
|
||||||
trie(): node(trie_t) {}
|
trie(): node(trie_t) {}
|
||||||
|
|
||||||
~trie() override {
|
|
||||||
}
|
|
||||||
|
|
||||||
node* find_or_insert(Key k, node* n) {
|
node* find_or_insert(Key k, node* n) {
|
||||||
for (unsigned i = 0; i < m_nodes.size(); ++i) {
|
for (unsigned i = 0; i < m_nodes.size(); ++i) {
|
||||||
if (m_nodes[i].first == k) {
|
if (m_nodes[i].first == k) {
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/binary_heap_priority_queue.h"
|
#include "math/lp/binary_heap_priority_queue.h"
|
||||||
namespace lp {
|
namespace lp {
|
||||||
|
|
|
@ -17,6 +17,7 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <set>
|
#include <set>
|
||||||
#include "math/lp/lp_utils.h"
|
#include "math/lp/lp_utils.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <limits>
|
#include <limits>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/lp/lp_settings.h"
|
#include "math/lp/lp_settings.h"
|
||||||
#ifdef Z3DEBUG
|
#ifdef Z3DEBUG
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
|
|
|
@ -28,8 +28,8 @@ namespace nla {
|
||||||
const monic& m_rm;
|
const monic& m_rm;
|
||||||
|
|
||||||
factorization_factory_imp(const monic& rm, const core& s);
|
factorization_factory_imp(const monic& rm, const core& s);
|
||||||
bool find_canonical_monic_of_vars(const svector<lpvar>& vars, unsigned & i) const;
|
bool find_canonical_monic_of_vars(const svector<lpvar>& vars, unsigned & i) const override;
|
||||||
virtual bool canonize_sign(const monic& m) const;
|
bool canonize_sign(const monic& m) const override;
|
||||||
virtual bool canonize_sign(const factorization& m) const;
|
bool canonize_sign(const factorization& m) const override;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/indexed_vector.h"
|
#include "math/lp/indexed_vector.h"
|
||||||
#include "math/lp/lp_settings.h"
|
#include "math/lp/lp_settings.h"
|
||||||
|
|
|
@ -9,6 +9,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/lar_core_solver.h"
|
#include "math/lp/lar_core_solver.h"
|
||||||
|
|
|
@ -543,7 +543,7 @@ public:
|
||||||
void get_model(std::unordered_map<var_index, mpq> & variable_values) const;
|
void get_model(std::unordered_map<var_index, mpq> & variable_values) const;
|
||||||
void get_rid_of_inf_eps();
|
void get_rid_of_inf_eps();
|
||||||
void get_model_do_not_care_about_diff_vars(std::unordered_map<var_index, mpq> & variable_values) const;
|
void get_model_do_not_care_about_diff_vars(std::unordered_map<var_index, mpq> & variable_values) const;
|
||||||
std::string get_variable_name(var_index vi) const;
|
std::string get_variable_name(var_index vi) const override;
|
||||||
void set_variable_name(var_index vi, std::string);
|
void set_variable_name(var_index vi, std::string);
|
||||||
inline unsigned number_of_vars() const { return m_var_register.size(); }
|
inline unsigned number_of_vars() const { return m_var_register.size(); }
|
||||||
inline bool is_base(unsigned j) const { return m_mpq_lar_core_solver.m_r_heading[j] >= 0; }
|
inline bool is_base(unsigned j) const { return m_mpq_lar_core_solver.m_r_heading[j] >= 0; }
|
||||||
|
@ -651,7 +651,7 @@ public:
|
||||||
lar_solver();
|
lar_solver();
|
||||||
void set_track_pivoted_rows(bool v);
|
void set_track_pivoted_rows(bool v);
|
||||||
bool get_track_pivoted_rows() const;
|
bool get_track_pivoted_rows() const;
|
||||||
virtual ~lar_solver();
|
~lar_solver() override;
|
||||||
const vector<impq>& r_x() const { return m_mpq_lar_core_solver.m_r_x; }
|
const vector<impq>& r_x() const { return m_mpq_lar_core_solver.m_r_x; }
|
||||||
bool column_is_int(unsigned j) const;
|
bool column_is_int(unsigned j) const;
|
||||||
inline bool column_value_is_int(unsigned j) const { return m_mpq_lar_core_solver.m_r_x[j].is_int(); }
|
inline bool column_value_is_int(unsigned j) const { return m_mpq_lar_core_solver.m_r_x[j].is_int(); }
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/lp/lp_dual_simplex.h"
|
#include "math/lp/lp_dual_simplex.h"
|
||||||
namespace lp{
|
namespace lp{
|
||||||
|
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <list>
|
#include <list>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
// this is a part of lp_primal_core_solver that deals with the tableau
|
// this is a part of lp_primal_core_solver that deals with the tableau
|
||||||
#include "math/lp/lp_primal_core_solver.h"
|
#include "math/lp/lp_primal_core_solver.h"
|
||||||
namespace lp {
|
namespace lp {
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/lp_primal_simplex.h"
|
#include "math/lp/lp_primal_simplex.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
|
|
|
@ -149,7 +149,7 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
virtual ~lp_solver();
|
~lp_solver() override;
|
||||||
|
|
||||||
void flip_costs();
|
void flip_costs();
|
||||||
|
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
|
@ -17,6 +17,7 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/permutation_matrix.h"
|
#include "math/lp/permutation_matrix.h"
|
||||||
namespace lp {
|
namespace lp {
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/lp/random_updater.h"
|
#include "math/lp/random_updater.h"
|
||||||
#include "math/lp/static_matrix.h"
|
#include "math/lp/static_matrix.h"
|
||||||
#include "math/lp/lar_solver.h"
|
#include "math/lp/lar_solver.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/row_eta_matrix.h"
|
#include "math/lp/row_eta_matrix.h"
|
||||||
namespace lp {
|
namespace lp {
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include "math/lp/scaler.h"
|
#include "math/lp/scaler.h"
|
||||||
#include "math/lp/numeric_pair.h"
|
#include "math/lp/numeric_pair.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/square_dense_submatrix.h"
|
#include "math/lp/square_dense_submatrix.h"
|
||||||
namespace lp {
|
namespace lp {
|
||||||
|
|
|
@ -17,6 +17,7 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include "math/lp/square_sparse_matrix.h"
|
#include "math/lp/square_sparse_matrix.h"
|
||||||
|
|
|
@ -17,6 +17,8 @@ Revision History:
|
||||||
|
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "util/vector.h"
|
#include "util/vector.h"
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
|
@ -38,7 +38,6 @@ namespace subpaving {
|
||||||
CTX m_ctx;
|
CTX m_ctx;
|
||||||
public:
|
public:
|
||||||
context_wrapper(reslimit& lim, typename CTX::numeral_manager & m, params_ref const & p, small_object_allocator * a):m_ctx(lim, m, p, a) {}
|
context_wrapper(reslimit& lim, typename CTX::numeral_manager & m, params_ref const & p, small_object_allocator * a):m_ctx(lim, m, p, a) {}
|
||||||
~context_wrapper() override {}
|
|
||||||
unsigned num_vars() const override { return m_ctx.num_vars(); }
|
unsigned num_vars() const override { return m_ctx.num_vars(); }
|
||||||
var mk_var(bool is_int) override { return m_ctx.mk_var(is_int); }
|
var mk_var(bool is_int) override { return m_ctx.mk_var(is_int); }
|
||||||
bool is_int(var x) const override { return m_ctx.is_int(x); }
|
bool is_int(var x) const override { return m_ctx.is_int(x); }
|
||||||
|
@ -66,8 +65,6 @@ namespace subpaving {
|
||||||
m_as(m)
|
m_as(m)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
~context_mpq_wrapper() override {}
|
|
||||||
|
|
||||||
unsynch_mpq_manager & qm() const override { return m_ctx.nm(); }
|
unsynch_mpq_manager & qm() const override { return m_ctx.nm(); }
|
||||||
|
|
||||||
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
||||||
|
@ -108,8 +105,6 @@ namespace subpaving {
|
||||||
m_q2(m_qm) {
|
m_q2(m_qm) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~context_mpf_wrapper() override {}
|
|
||||||
|
|
||||||
unsynch_mpq_manager & qm() const override { return m_qm; }
|
unsynch_mpq_manager & qm() const override { return m_qm; }
|
||||||
|
|
||||||
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
||||||
|
@ -165,8 +160,6 @@ namespace subpaving {
|
||||||
m_qm(qm) {
|
m_qm(qm) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~context_hwf_wrapper() override {}
|
|
||||||
|
|
||||||
unsynch_mpq_manager & qm() const override { return m_qm; }
|
unsynch_mpq_manager & qm() const override { return m_qm; }
|
||||||
|
|
||||||
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
||||||
|
@ -223,8 +216,6 @@ namespace subpaving {
|
||||||
m_z2(m_qm) {
|
m_z2(m_qm) {
|
||||||
}
|
}
|
||||||
|
|
||||||
~context_fpoint_wrapper() override {}
|
|
||||||
|
|
||||||
unsynch_mpq_manager & qm() const override { return m_qm; }
|
unsynch_mpq_manager & qm() const override { return m_qm; }
|
||||||
|
|
||||||
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
var mk_sum(mpz const & c, unsigned sz, mpz const * as, var const * xs) override {
|
||||||
|
|
|
@ -16,6 +16,8 @@ Author:
|
||||||
Revision History:
|
Revision History:
|
||||||
|
|
||||||
--*/
|
--*/
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include "math/subpaving/subpaving_t.h"
|
#include "math/subpaving/subpaving_t.h"
|
||||||
#include "math/interval/interval_def.h"
|
#include "math/interval/interval_def.h"
|
||||||
#include "util/buffer.h"
|
#include "util/buffer.h"
|
||||||
|
|
|
@ -37,8 +37,6 @@ class subpaving_tactic : public tactic {
|
||||||
e2v.mk_inv(m_inv);
|
e2v.mk_inv(m_inv);
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual ~display_var_proc() {}
|
|
||||||
|
|
||||||
ast_manager & m() const { return m_inv.get_manager(); }
|
ast_manager & m() const { return m_inv.get_manager(); }
|
||||||
|
|
||||||
void operator()(std::ostream & out, subpaving::var x) const override {
|
void operator()(std::ostream & out, subpaving::var x) const override {
|
||||||
|
|
|
@ -32,8 +32,6 @@ class array_factory : public struct_factory {
|
||||||
public:
|
public:
|
||||||
array_factory(ast_manager & m, model_core & md);
|
array_factory(ast_manager & m, model_core & md);
|
||||||
|
|
||||||
~array_factory() override {}
|
|
||||||
|
|
||||||
expr * get_some_value(sort * s) override;
|
expr * get_some_value(sort * s) override;
|
||||||
|
|
||||||
bool get_some_values(sort * s, expr_ref & v1, expr_ref & v2) override;
|
bool get_some_values(sort * s, expr_ref & v1, expr_ref & v2) override;
|
||||||
|
|
|
@ -32,7 +32,6 @@ class datatype_factory : public struct_factory {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
datatype_factory(ast_manager & m, model_core & md);
|
datatype_factory(ast_manager & m, model_core & md);
|
||||||
~datatype_factory() override {}
|
|
||||||
expr * get_some_value(sort * s) override;
|
expr * get_some_value(sort * s) override;
|
||||||
expr * get_fresh_value(sort * s) override;
|
expr * get_fresh_value(sort * s) override;
|
||||||
};
|
};
|
||||||
|
|
|
@ -34,8 +34,6 @@ class fpa_value_factory : public value_factory {
|
||||||
value_factory(m, fid),
|
value_factory(m, fid),
|
||||||
m_util(m) {}
|
m_util(m) {}
|
||||||
|
|
||||||
~fpa_value_factory() override {}
|
|
||||||
|
|
||||||
expr * get_some_value(sort * s) override {
|
expr * get_some_value(sort * s) override {
|
||||||
mpf_manager & mpfm = m_util.fm();
|
mpf_manager & mpfm = m_util.fm();
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,6 @@ Revision History:
|
||||||
class numeral_factory : public simple_factory<rational> {
|
class numeral_factory : public simple_factory<rational> {
|
||||||
public:
|
public:
|
||||||
numeral_factory(ast_manager & m, family_id fid):simple_factory<rational>(m, fid) {}
|
numeral_factory(ast_manager & m, family_id fid):simple_factory<rational>(m, fid) {}
|
||||||
~numeral_factory() override {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class arith_factory : public numeral_factory {
|
class arith_factory : public numeral_factory {
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue