[llvm] r249783 - Support: Partially revert r249782 to unbreak clang build

Duncan P. N. Exon Smith via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 8 17:03:57 PDT 2015


Author: dexonsmith
Date: Thu Oct  8 19:03:57 2015
New Revision: 249783

URL: http://llvm.org/viewvc/llvm-project?rev=249783&view=rev
Log:
Support: Partially revert r249782 to unbreak clang build

Apparently the iterators in `clang::CFGBlock` have an auto-conversion to
`CFGBlock *`, but the dereference operator gives `const CFGBlock &`.
Until I have a moment to fix that, revert the GenericDomTree chagnes
from r249782.

Modified:
    llvm/trunk/include/llvm/Support/GenericDomTree.h

Modified: llvm/trunk/include/llvm/Support/GenericDomTree.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/GenericDomTree.h?rev=249783&r1=249782&r2=249783&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/GenericDomTree.h (original)
+++ llvm/trunk/include/llvm/Support/GenericDomTree.h Thu Oct  8 19:03:57 2015
@@ -734,13 +734,13 @@ public:
       for (typename TraitsTy::nodes_iterator I = TraitsTy::nodes_begin(&F),
                                              E = TraitsTy::nodes_end(&F);
            I != E; ++I) {
-        if (TraitsTy::child_begin(&*I) == TraitsTy::child_end(&*I))
-          addRoot(&*I);
+        if (TraitsTy::child_begin(I) == TraitsTy::child_end(I))
+          addRoot(I);
 
         // Prepopulate maps so that we don't get iterator invalidation issues
         // later.
-        this->IDoms[&*I] = nullptr;
-        this->DomTreeNodes[&*I] = nullptr;
+        this->IDoms[I] = nullptr;
+        this->DomTreeNodes[I] = nullptr;
       }
 
       Calculate<FT, Inverse<NodeT *>>(*this, F);




More information about the llvm-commits mailing list