Fix build with GCC.
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Sat, 19 Jul 2014 19:16:36 +0000 (19:16 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Sat, 19 Jul 2014 19:16:36 +0000 (19:16 +0000)
Seems like a bug in either GCC or clang, but I'm
not sure which is right.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@213460 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Analysis/RegionInfo.h

index cdf8277e02cfb9cc87c94eebd7a43d49273a4f08..40c43db710492d3c2afff1eb6c896ba7f1114621 100644 (file)
@@ -312,7 +312,9 @@ public:
 
   /// @brief Get the entry BasicBlock of the Region.
   /// @return The entry BasicBlock of the region.
-  BlockT *getEntry() const { return RegionNodeT::getEntry(); }
+  BlockT *getEntry() const {
+    return RegionNodeBase<Tr>::getEntry();
+  }
 
   /// @brief Replace the entry basic block of the region with the new basic
   ///        block.
@@ -352,7 +354,9 @@ public:
   /// @brief Get the parent of the Region.
   /// @return The parent of the Region or NULL if this is a top level
   ///         Region.
-  RegionT *getParent() const { return RegionNodeT::getParent(); }
+  RegionT *getParent() const {
+    return RegionNodeBase<Tr>::getParent();
+  }
 
   /// @brief Get the RegionNode representing the current Region.
   /// @return The RegionNode representing the current Region.
@@ -666,7 +670,7 @@ class RegionInfoBase {
   typedef SmallPtrSet<RegionT *, 4> RegionSet;
 
   RegionInfoBase();
-  ~RegionInfoBase();
+  virtual ~RegionInfoBase();
 
   RegionInfoBase(const RegionInfoBase &) LLVM_DELETED_FUNCTION;
   const RegionInfoBase &operator=(const RegionInfoBase &) LLVM_DELETED_FUNCTION;