GCC Code Coverage Report
Directory: . Exec Total Coverage
File: src/preprocessing/passes/theory_rewrite_eq.h Lines: 1 1 100.0 %
Date: 2021-03-22 Branches: 0 0 0.0 %

Line Exec Source
1
/*********************                                                        */
2
/*! \file theory_rewrite_eq.h
3
 ** \verbatim
4
 ** Top contributors (to current version):
5
 **   Andrew Reynolds
6
 ** This file is part of the CVC4 project.
7
 ** Copyright (c) 2009-2021 by the authors listed in the file AUTHORS
8
 ** in the top-level source directory and their institutional affiliations.
9
 ** All rights reserved.  See the file COPYING in the top-level source
10
 ** directory for licensing information.\endverbatim
11
 **
12
 ** \brief The TheoryRewriteEq preprocessing pass
13
 **/
14
15
#include "cvc4_private.h"
16
17
#ifndef CVC4__PREPROCESSING__PASSES__THEORY_REWRITE_EQ_H
18
#define CVC4__PREPROCESSING__PASSES__THEORY_REWRITE_EQ_H
19
20
#include "expr/node.h"
21
#include "preprocessing/preprocessing_pass.h"
22
#include "theory/trust_node.h"
23
24
namespace CVC4 {
25
namespace preprocessing {
26
namespace passes {
27
28
/**
29
 * Implements the preprocessing pass for called ppRewrite on all equalities
30
 * in the input. This is required to be a preprocessing pass since it is not
31
 * recommended that ppRewrite is called on equalities generated in lemmas (e.g.
32
 * it may interfere with equality splitting in theory combination).
33
 */
34
17984
class TheoryRewriteEq : public PreprocessingPass
35
{
36
 public:
37
  TheoryRewriteEq(PreprocessingPassContext* preprocContext);
38
39
 protected:
40
  PreprocessingPassResult applyInternal(
41
      AssertionPipeline* assertionsToPreprocess) override;
42
  /**
43
   * Rewrite the assertion based on rewriting equalities based on theory
44
   * specific rewriting.
45
   * An example is removing arithmetic equalities via:
46
   *   (= x y) ---> (and (>= x y) (<= x y))
47
   * Returns the trust node corresponding to the rewrite.
48
   */
49
  theory::TrustNode rewriteAssertion(TNode assertion);
50
};
51
52
}  // namespace passes
53
}  // namespace preprocessing
54
}  // namespace CVC4
55
56
#endif /* CVC4__PREPROCESSING__PASSES__THEORY_REWRITE_EQ_H */