From b385b7c62ea31004832c74ee0da92a71af774fd2 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Fri, 9 Oct 2009 22:56:12 +0000 Subject: Dead Code Elimination llvm-svn: 83686 --- clang/lib/Sema/Sema.h | 3 --- clang/lib/Sema/SemaLookup.cpp | 20 -------------------- 2 files changed, 23 deletions(-) (limited to 'clang/lib') diff --git a/clang/lib/Sema/Sema.h b/clang/lib/Sema/Sema.h index d319969ccec..33d7468787d 100644 --- a/clang/lib/Sema/Sema.h +++ b/clang/lib/Sema/Sema.h @@ -1272,9 +1272,6 @@ public: DeclarationName Name, LookupNameKind NameKind, bool RedeclarationOnly = false); - Decl *LookupQualifiedNameWithType(DeclContext *LookupCtx, - DeclarationName Name, - QualType T); bool LookupParsedName(LookupResult &R, Scope *S, const CXXScopeSpec *SS, DeclarationName Name, LookupNameKind NameKind, diff --git a/clang/lib/Sema/SemaLookup.cpp b/clang/lib/Sema/SemaLookup.cpp index 1c6e9368278..aad12ccaa83 100644 --- a/clang/lib/Sema/SemaLookup.cpp +++ b/clang/lib/Sema/SemaLookup.cpp @@ -1352,26 +1352,6 @@ ObjCCategoryImplDecl *Sema::LookupObjCCategoryImpl(IdentifierInfo *II) { return cast_or_null(D); } -// Attempts to find a declaration in the given declaration context -// with exactly the given type. Returns null if no such declaration -// was found. -Decl *Sema::LookupQualifiedNameWithType(DeclContext *DC, - DeclarationName Name, - QualType T) { - LookupResult result; - LookupQualifiedName(result, DC, Name, LookupOrdinaryName, true); - - CanQualType CQT = Context.getCanonicalType(T); - - for (LookupResult::iterator ir = result.begin(), ie = result.end(); - ir != ie; ++ir) - if (FunctionDecl *CurFD = dyn_cast(*ir)) - if (Context.getCanonicalType(CurFD->getType()) == CQT) - return CurFD; - - return NULL; -} - void Sema::LookupOverloadedOperatorName(OverloadedOperatorKind Op, Scope *S, QualType T1, QualType T2, FunctionSet &Functions) { -- cgit v1.2.3