From 5d65e34b08b3e57a4da834195757d0d15baaffd0 Mon Sep 17 00:00:00 2001 From: Chandler Carruth Date: Sun, 1 May 2011 21:29:41 +0000 Subject: [PATCH] Switch getAs to castAs (didn't know about this before!) and simplify some code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130665 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/AST/Type.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/clang/AST/Type.h b/include/clang/AST/Type.h index 77d704126c..975a66fefa 100644 --- a/include/clang/AST/Type.h +++ b/include/clang/AST/Type.h @@ -2989,7 +2989,7 @@ class TemplateTypeParmType : public Type, public llvm::FoldingSetNode { TemplateTypeParmType(TemplateTypeParmDecl *TTPDecl, QualType Canon) : Type(TemplateTypeParm, Canon, /*Dependent=*/true, /*VariablyModified=*/false, - Canon->getAs()->CanTTPTInfo.ParameterPack), + Canon->containsUnexpandedParameterPack()), TTPDecl(TTPDecl) { } /// Build the canonical type. @@ -3005,7 +3005,7 @@ class TemplateTypeParmType : public Type, public llvm::FoldingSetNode { const CanonicalTTPTInfo& getCanTTPTInfo() const { QualType Can = getCanonicalTypeInternal(); - return Can->getAs()->CanTTPTInfo; + return Can->castAs()->CanTTPTInfo; } public: -- 2.40.0