mirror of
https://github.com/Z3Prover/z3
synced 2026-07-18 04:55:45 +00:00
This is another PR towards the goal of getting Z3 to compile cleanly when included via FetchContents into clang-tidy, which uses a pretty strict set of warnings. This is a second version of https://github.com/Z3Prover/z3/pull/9957. I address @NikolajBjorner 's comments about not changing the semicolons after macro invocations, because some editors work better with them present. It now, to the best of my ability, only deletes semis: * after the closing brace of namespace decl. * after the closing brace of an extern "C" decl. * after a function definition. This PR is very large, but it consists entirely of deletions of semicolons in these situations. (If there was a way to update the previous PR, which had been closed, and that is preferable, please let me know. I couldn't figure it out.)
54 lines
1.4 KiB
C++
54 lines
1.4 KiB
C++
|
|
/*++
|
|
Copyright (c) 2018 Microsoft Corporation
|
|
|
|
Module Name:
|
|
|
|
smt_arith_value.h
|
|
|
|
Abstract:
|
|
|
|
Utility to extract arithmetic values from context.
|
|
|
|
Author:
|
|
|
|
Nikolaj Bjorner (nbjorner) 2018-12-08.
|
|
|
|
Revision History:
|
|
|
|
--*/
|
|
#pragma once
|
|
|
|
#include "ast/arith_decl_plugin.h"
|
|
#include "smt/smt_context.h"
|
|
#include "smt/theory_lra.h"
|
|
#include "smt/theory_arith.h"
|
|
#include "smt/theory_bv.h"
|
|
|
|
namespace smt {
|
|
class arith_value {
|
|
context* m_ctx;
|
|
ast_manager& m;
|
|
arith_util a;
|
|
bv_util b;
|
|
theory_mi_arith* m_tha;
|
|
theory_i_arith* m_thi;
|
|
theory_lra* m_thr;
|
|
theory_bv* m_thb;
|
|
public:
|
|
arith_value(ast_manager& m);
|
|
void init(context* ctx);
|
|
bool get_lo_equiv(expr* e, rational& lo, bool& strict);
|
|
bool get_up_equiv(expr* e, rational& up, bool& strict);
|
|
bool get_value_equiv(expr* e, rational& value) const;
|
|
bool get_lo(expr* e, rational& lo, bool& strict) const;
|
|
bool get_up(expr* e, rational& up, bool& strict) const;
|
|
bool get_value(expr* e, rational& value) const;
|
|
expr_ref get_lo(expr* e) const;
|
|
expr_ref get_up(expr* e) const;
|
|
expr_ref get_fixed(expr* e) const;
|
|
final_check_status final_check(unsigned );
|
|
lbool check_lp_feasible(vector<std::pair<bool, expr_ref>> &ineqs, literal_vector &lit_core,
|
|
enode_pair_vector &eq_core);
|
|
};
|
|
}
|