[cfe-commits] r83686 - in /cfe/trunk/lib/Sema: Sema.h SemaLookup.cpp
Douglas Gregor
dgregor at apple.com
Fri Oct 9 15:56:12 PDT 2009
Author: dgregor
Date: Fri Oct 9 17:56:12 2009
New Revision: 83686
URL: http://llvm.org/viewvc/llvm-project?rev=83686&view=rev
Log:
Dead Code Elimination
Modified:
cfe/trunk/lib/Sema/Sema.h
cfe/trunk/lib/Sema/SemaLookup.cpp
Modified: cfe/trunk/lib/Sema/Sema.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/Sema.h?rev=83686&r1=83685&r2=83686&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/Sema.h (original)
+++ cfe/trunk/lib/Sema/Sema.h Fri Oct 9 17:56:12 2009
@@ -1272,9 +1272,6 @@
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,
Modified: cfe/trunk/lib/Sema/SemaLookup.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaLookup.cpp?rev=83686&r1=83685&r2=83686&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaLookup.cpp (original)
+++ cfe/trunk/lib/Sema/SemaLookup.cpp Fri Oct 9 17:56:12 2009
@@ -1352,26 +1352,6 @@
return cast_or_null<ObjCCategoryImplDecl>(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<FunctionDecl>(*ir))
- if (Context.getCanonicalType(CurFD->getType()) == CQT)
- return CurFD;
-
- return NULL;
-}
-
void Sema::LookupOverloadedOperatorName(OverloadedOperatorKind Op, Scope *S,
QualType T1, QualType T2,
FunctionSet &Functions) {
More information about the cfe-commits
mailing list