Update for Clang API change in r230123 -- lookup_result was always
authorChandler Carruth <chandlerc@gmail.com>
Sat, 21 Feb 2015 04:31:13 +0000 (04:31 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Sat, 21 Feb 2015 04:31:13 +0000 (04:31 +0000)
const, there was never a need for lookup_const_result. Now that vestigal
type is gone, so switch LLDB to lookup_result and to use the
DeclContextLookupResult rather than the Const variant.

llvm-svn: 230126

lldb/include/lldb/Expression/ClangASTSource.h
lldb/include/lldb/Symbol/ClangASTContext.h
lldb/source/Expression/ClangASTSource.cpp
lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCDeclVendor.cpp

index 3e41a9e..23977fc 100644 (file)
@@ -513,7 +513,7 @@ struct NameSearchContext {
     ///     The DeclContextLookupResult, usually returned as the result
     ///     of querying a DeclContext.
     //------------------------------------------------------------------
-    void AddLookupResult (clang::DeclContextLookupConstResult result);
+    void AddLookupResult (clang::DeclContextLookupResult result);
     
     //------------------------------------------------------------------
     /// Add a NamedDecl to the list of results.
index a9096fe..a411e42 100644 (file)
@@ -235,7 +235,7 @@ public:
                 clang::IdentifierInfo &myIdent = ast->Idents.get(type_name.GetCString());
                 clang::DeclarationName myName = ast->DeclarationNames.getIdentifier(&myIdent);
                 
-                clang::DeclContext::lookup_const_result result = ast->getTranslationUnitDecl()->lookup(myName);
+                clang::DeclContext::lookup_result result = ast->getTranslationUnitDecl()->lookup(myName);
                 
                 if (!result.empty())
                 {
index 9a6d6e5..6103738 100644 (file)
@@ -2008,7 +2008,7 @@ NameSearchContext::AddTypeDecl(const ClangASTType &clang_type)
 }
 
 void
-NameSearchContext::AddLookupResult (clang::DeclContextLookupConstResult result)
+NameSearchContext::AddLookupResult (clang::DeclContextLookupResult result)
 {
     for (clang::NamedDecl *decl : result)
         m_decls.push_back (decl);
index e76e612..ee5e318 100644 (file)
@@ -60,7 +60,7 @@ public:
             if (!m_decl_vendor.FinishDecl(non_const_interface_decl))
                 break;
 
-            clang::DeclContext::lookup_const_result result = non_const_interface_decl->lookup(name);
+            clang::DeclContext::lookup_result result = non_const_interface_decl->lookup(name);
 
             return (result.size() != 0);
         }
@@ -588,7 +588,7 @@ AppleObjCDeclVendor::FindDecls (const ConstString &name,
         clang::IdentifierInfo &identifier_info = ast_ctx->Idents.get(name.GetStringRef());
         clang::DeclarationName decl_name = ast_ctx->DeclarationNames.getIdentifier(&identifier_info);
         
-        clang::DeclContext::lookup_const_result lookup_result = ast_ctx->getTranslationUnitDecl()->lookup(decl_name);
+        clang::DeclContext::lookup_result lookup_result = ast_ctx->getTranslationUnitDecl()->lookup(decl_name);
         
         if (!lookup_result.empty())
         {