summaryrefslogtreecommitdiff
path: root/src/expr/proof_rule.cpp
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2020-04-15 17:09:40 -0500
committerGitHub <noreply@github.com>2020-04-15 17:09:40 -0500
commit912b65006615fe4074cde54b080f48e3d6c12042 (patch)
tree99b1d0ad565ac79d7ebaaa305a42d5052d06b206 /src/expr/proof_rule.cpp
parenteacb636406e609299b6e5b64e93f1cf5b73f4ba3 (diff)
Add ProofNode data structure (#4311)
This is the core data structure for proofs in the new proofs infrastructure. PfRule is a global enumeration of ids of proof nodes (analogous to Kind for Nodes).
Diffstat (limited to 'src/expr/proof_rule.cpp')
-rw-r--r--src/expr/proof_rule.cpp39
1 files changed, 39 insertions, 0 deletions
diff --git a/src/expr/proof_rule.cpp b/src/expr/proof_rule.cpp
new file mode 100644
index 000000000..2c10e09e6
--- /dev/null
+++ b/src/expr/proof_rule.cpp
@@ -0,0 +1,39 @@
+/********************* */
+/*! \file proof_rule.cpp
+ ** \verbatim
+ ** Top contributors (to current version):
+ ** Andrew Reynolds
+ ** This file is part of the CVC4 project.
+ ** Copyright (c) 2009-2019 by the authors listed in the file AUTHORS
+ ** in the top-level source directory) and their institutional affiliations.
+ ** All rights reserved. See the file COPYING in the top-level source
+ ** directory for licensing information.\endverbatim
+ **
+ ** \brief Implementation of proof rule
+ **/
+
+#include "expr/proof_rule.h"
+
+#include <iostream>
+
+namespace CVC4 {
+
+const char* toString(PfRule id)
+{
+ switch (id)
+ {
+ //================================================= Core rules
+ case PfRule::ASSUME: return "ASSUME";
+ //================================================= Unknown rule
+ case PfRule::UNKNOWN: return "UNKNOWN";
+ default: return "?";
+ }
+}
+
+std::ostream& operator<<(std::ostream& out, PfRule id)
+{
+ out << toString(id);
+ return out;
+}
+
+} // namespace CVC4
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback