[cfe-commits] r130665 - /cfe/trunk/include/clang/AST/Type.h
Chandler Carruth
chandlerc at gmail.com
Sun May 1 14:29:41 PDT 2011
Author: chandlerc
Date: Sun May 1 16:29:41 2011
New Revision: 130665
URL: http://llvm.org/viewvc/llvm-project?rev=130665&view=rev
Log:
Switch getAs to castAs (didn't know about this before!) and simplify
some code.
Modified:
cfe/trunk/include/clang/AST/Type.h
Modified: cfe/trunk/include/clang/AST/Type.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Type.h?rev=130665&r1=130664&r2=130665&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/Type.h (original)
+++ cfe/trunk/include/clang/AST/Type.h Sun May 1 16:29:41 2011
@@ -2989,7 +2989,7 @@
TemplateTypeParmType(TemplateTypeParmDecl *TTPDecl, QualType Canon)
: Type(TemplateTypeParm, Canon, /*Dependent=*/true,
/*VariablyModified=*/false,
- Canon->getAs<TemplateTypeParmType>()->CanTTPTInfo.ParameterPack),
+ Canon->containsUnexpandedParameterPack()),
TTPDecl(TTPDecl) { }
/// Build the canonical type.
@@ -3005,7 +3005,7 @@
const CanonicalTTPTInfo& getCanTTPTInfo() const {
QualType Can = getCanonicalTypeInternal();
- return Can->getAs<TemplateTypeParmType>()->CanTTPTInfo;
+ return Can->castAs<TemplateTypeParmType>()->CanTTPTInfo;
}
public:
More information about the cfe-commits
mailing list