Refactor the code that walks a C++ inheritance hierarchy, searching
for bases, members, overridden virtual methods, etc. The operations
isDerivedFrom and lookupInBases are now provided by CXXRecordDecl,
rather than by Sema, so that CodeGen and other clients can use them
directly.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83396 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 4e9d7de..86a5ad8 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -11,9 +11,9 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "SemaInherit.h"
 #include "Sema.h"
 #include "clang/AST/ASTContext.h"
+#include "clang/AST/CXXInheritance.h"
 #include "clang/AST/ExprCXX.h"
 #include "clang/Basic/PartialDiagnostic.h"
 #include "clang/Basic/TargetInfo.h"
@@ -1322,8 +1322,8 @@
 
   if (Context.getCanonicalType(Class).getUnqualifiedType() !=
       Context.getCanonicalType(LType).getUnqualifiedType()) {
-    BasePaths Paths(/*FindAmbiguities=*/true, /*RecordPaths=*/false,
-                    /*DetectVirtual=*/false);
+    CXXBasePaths Paths(/*FindAmbiguities=*/true, /*RecordPaths=*/false,
+                       /*DetectVirtual=*/false);
     // FIXME: Would it be useful to print full ambiguity paths, or is that
     // overkill?
     if (!IsDerivedFrom(LType, Class, Paths) ||