3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-10-26 01:14:36 +00:00

[spacer] implement spacer::is_clause() (#4170)

Spacer has a different defintion of is_clause() than ast_util.
It is currently only used in assertions.

Main difference:
  x=y
where x and y are Bool atoms is considered to be an atom, so that
(or (= x y) (not (= z y)))
is a literal

Co-authored-by: Arie Gurfinkel <arie.gurfinkel@uwaterloo.ca>
This commit is contained in:
Hari Govind V K 2020-04-30 17:03:48 -04:00 committed by GitHub
parent 799b6131f2
commit dbfa3dd7f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 48 additions and 4 deletions

View file

@ -136,6 +136,10 @@ namespace spacer {
mk_epp(ast *t, ast_manager &m, unsigned indent = 0, unsigned num_vars = 0, char const * var_prefix = nullptr);
void rw(expr *e, expr_ref &out);
};
bool is_clause(ast_manager &m, expr *n);
bool is_literal(ast_manager &m, expr *n);
bool is_atom(ast_manager &m, expr *n);
}
#endif