summaryrefslogtreecommitdiff
path: root/src/theory/rewriter_tables_template.h
diff options
context:
space:
mode:
authorDejan Jovanović <dejan.jovanovic@gmail.com>2011-01-05 03:21:35 +0000
committerDejan Jovanović <dejan.jovanovic@gmail.com>2011-01-05 03:21:35 +0000
commitf9a4fe48a4ec2355f8fec93d3f47242577df2511 (patch)
treeeb49b7760b16aa17666d59464c96979b445fbcc8 /src/theory/rewriter_tables_template.h
parenteecc1e4f301711dbb2bf1508ea0ba6cd20acd593 (diff)
Commit for the theory engine and rewriter changes. Changes are substantial and not yet finalized but I need to put it in to work further with the theory writers. Please check the files that you 'own'. Any comments or discussion is welcome. Further details will be coming in a follow up email later.
Diffstat (limited to 'src/theory/rewriter_tables_template.h')
-rw-r--r--src/theory/rewriter_tables_template.h69
1 files changed, 69 insertions, 0 deletions
diff --git a/src/theory/rewriter_tables_template.h b/src/theory/rewriter_tables_template.h
new file mode 100644
index 000000000..e26c879e4
--- /dev/null
+++ b/src/theory/rewriter_tables_template.h
@@ -0,0 +1,69 @@
+#pragma once
+
+#include "theory/rewriter.h"
+#include "theory/rewriter_attributes.h"
+
+${rewriter_includes}
+
+namespace CVC4 {
+namespace theory {
+
+RewriteResponse Rewriter::callPreRewrite(theory::TheoryId theoryId, TNode node) {
+ switch(theoryId) {
+${pre_rewrite_calls}
+ default:
+ Unreachable();
+ }
+}
+
+RewriteResponse Rewriter::callPostRewrite(theory::TheoryId theoryId, TNode node) {
+ switch(theoryId) {
+${post_rewrite_calls}
+ default:
+ Unreachable();
+ }
+}
+
+Node Rewriter::getPreRewriteCache(theory::TheoryId theoryId, TNode node) {
+ switch(theoryId) {
+${pre_rewrite_get_cache}
+ default:
+ Unreachable();
+ }
+}
+
+Node Rewriter::getPostRewriteCache(theory::TheoryId theoryId, TNode node) {
+ switch(theoryId) {
+${post_rewrite_get_cache}
+ default:
+ Unreachable();
+ }
+}
+
+void Rewriter::setPreRewriteCache(theory::TheoryId theoryId, TNode node, TNode cache) {
+ switch(theoryId) {
+${pre_rewrite_set_cache}
+ default:
+ Unreachable();
+ }
+}
+
+void Rewriter::setPostRewriteCache(theory::TheoryId theoryId, TNode node, TNode cache) {
+ switch(theoryId) {
+${post_rewrite_set_cache}
+ default:
+ Unreachable();
+ }
+}
+
+
+void Rewriter::init() {
+${rewrite_init}
+}
+
+void Rewriter::shutdown() {
+${rewrite_shutdown}
+}
+
+}
+}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback