fix for theory preprocessing cache on clang, perhaps others.
authorMorgan Deters <mdeters@cs.nyu.edu>
Tue, 22 Jan 2013 23:03:46 +0000 (18:03 -0500)
committerMorgan Deters <mdeters@cs.nyu.edu>
Tue, 22 Jan 2013 23:03:46 +0000 (18:03 -0500)
src/theory/theory_engine.cpp

index c0aa5864765291be84058cc7faf9b73c79f7a331..2ea0e866fc5326e6cc4db5f9223ddfa6c8d5ad9b 100644 (file)
@@ -740,8 +740,7 @@ theory::Theory::PPAssertStatus TheoryEngine::solve(TNode literal, SubstitutionMa
 }
 
 // Recursively traverse a term and call the theory rewriter on its sub-terms
-Node TheoryEngine::ppTheoryRewrite(TNode term)
-{
+Node TheoryEngine::ppTheoryRewrite(TNode term) {
   NodeMap::iterator find = d_ppCache.find(term);
   if (find != d_ppCache.end()) {
     return (*find).second;
@@ -826,7 +825,8 @@ Node TheoryEngine::preprocess(TNode assertion) {
 
     // If this is an atom, we preprocess its terms with the theory ppRewriter
     if (Theory::theoryOf(current) != THEORY_BOOL) {
-      d_ppCache[current] = ppTheoryRewrite(current);
+      Node ppRewritten = ppTheoryRewrite(current);
+      d_ppCache[current] = ppRewritten;
       Assert(Rewriter::rewrite(d_ppCache[current]) == d_ppCache[current]);
       continue;
     }