diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-07-18 00:34:25 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-07-18 00:34:25 +0000 |
commit | 6b7e37616077495adc4f0fedccb7458b51817d66 (patch) | |
tree | c1a2f3002c0a3b51fc9af6ca4a4cf1a545949dd3 /clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | |
parent | 5614aef776d36e2eac36b8fef9c0ab356bb901d2 (diff) | |
download | bcm5719-llvm-6b7e37616077495adc4f0fedccb7458b51817d66.tar.gz bcm5719-llvm-6b7e37616077495adc4f0fedccb7458b51817d66.zip |
Remove ASTContext::getCanonicalDecl() and use Decl::getCanonicalDecl in its place.
llvm-svn: 76274
Diffstat (limited to 'clang/lib/Sema/SemaTemplateInstantiateDecl.cpp')
-rw-r--r-- | clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp b/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp index 8ff80af1903..49271893f93 100644 --- a/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp +++ b/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp @@ -781,16 +781,16 @@ static bool isInstantiationOf(ASTContext &Ctx, NamedDecl *D, Decl *Other) { return false; if (CXXRecordDecl *Record = dyn_cast<CXXRecordDecl>(Other)) - return Ctx.getCanonicalDecl(Record->getInstantiatedFromMemberClass()) - == Ctx.getCanonicalDecl(D); + return Record->getInstantiatedFromMemberClass()->getCanonicalDecl() + == D->getCanonicalDecl(); if (FunctionDecl *Function = dyn_cast<FunctionDecl>(Other)) - return Ctx.getCanonicalDecl(Function->getInstantiatedFromMemberFunction()) - == Ctx.getCanonicalDecl(D); + return Function->getInstantiatedFromMemberFunction()->getCanonicalDecl() + == D->getCanonicalDecl(); if (EnumDecl *Enum = dyn_cast<EnumDecl>(Other)) - return Ctx.getCanonicalDecl(Enum->getInstantiatedFromMemberEnum()) - == Ctx.getCanonicalDecl(D); + return Enum->getInstantiatedFromMemberEnum()->getCanonicalDecl() + == D->getCanonicalDecl(); // FIXME: How can we find instantiations of anonymous unions? @@ -891,8 +891,8 @@ NamedDecl * Sema::InstantiateCurrentDeclRef(NamedDecl *D) { DC = DC->getParent()) { if (ClassTemplateSpecializationDecl *Spec = dyn_cast<ClassTemplateSpecializationDecl>(DC)) - if (Context.getCanonicalDecl(Spec->getSpecializedTemplate()) - == Context.getCanonicalDecl(ClassTemplate)) + if (Spec->getSpecializedTemplate()->getCanonicalDecl() + == ClassTemplate->getCanonicalDecl()) return Spec; } |