aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/AST/Type.cpp2
-rw-r--r--lib/AST/TypePrinter.cpp2
-rw-r--r--lib/Sema/SemaTemplateVariadic.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/lib/AST/Type.cpp b/lib/AST/Type.cpp
index 1ed1770426..9eb497bea6 100644
--- a/lib/AST/Type.cpp
+++ b/lib/AST/Type.cpp
@@ -1504,7 +1504,7 @@ bool EnumType::classof(const TagType *TT) {
return isa<EnumDecl>(TT->getDecl());
}
-IdentifierInfo *TemplateTypeParmType::getName() const {
+IdentifierInfo *TemplateTypeParmType::getIdentifier() const {
return isCanonicalUnqualified() ? 0 : getDecl()->getIdentifier();
}
diff --git a/lib/AST/TypePrinter.cpp b/lib/AST/TypePrinter.cpp
index a0d40e14d7..0c5df7fae6 100644
--- a/lib/AST/TypePrinter.cpp
+++ b/lib/AST/TypePrinter.cpp
@@ -653,7 +653,7 @@ void TypePrinter::printTemplateTypeParm(const TemplateTypeParmType *T,
if (!S.empty()) // Prefix the basic type, e.g. 'parmname X'.
S = ' ' + S;
- if (IdentifierInfo *Id = T->getDecl() ? T->getDecl()->getIdentifier() : 0)
+ if (IdentifierInfo *Id = T->getIdentifier())
S = Id->getName().str() + S;
else
S = "type-parameter-" + llvm::utostr_32(T->getDepth()) + '-' +
diff --git a/lib/Sema/SemaTemplateVariadic.cpp b/lib/Sema/SemaTemplateVariadic.cpp
index 5c321fd6df..096d353bcc 100644
--- a/lib/Sema/SemaTemplateVariadic.cpp
+++ b/lib/Sema/SemaTemplateVariadic.cpp
@@ -167,7 +167,7 @@ DiagnoseUnexpandedParameterPacks(Sema &S, SourceLocation Loc,
IdentifierInfo *Name = 0;
if (const TemplateTypeParmType *TTP
= Unexpanded[I].first.dyn_cast<const TemplateTypeParmType *>())
- Name = TTP->getName();
+ Name = TTP->getIdentifier();
else
Name = Unexpanded[I].first.get<NamedDecl *>()->getIdentifier();
@@ -483,7 +483,7 @@ bool Sema::CheckParameterPacksForExpansion(SourceLocation EllipsisLoc,
= Unexpanded[I].first.dyn_cast<const TemplateTypeParmType *>()) {
Depth = TTP->getDepth();
Index = TTP->getIndex();
- Name = TTP->getName();
+ Name = TTP->getIdentifier();
} else {
NamedDecl *ND = Unexpanded[I].first.get<NamedDecl *>();
if (isa<ParmVarDecl>(ND))