diff options
-rw-r--r-- | clang/lib/AST/Type.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/AST/Type.cpp b/clang/lib/AST/Type.cpp index 0f7f6244d2a..8ab2f1e271e 100644 --- a/clang/lib/AST/Type.cpp +++ b/clang/lib/AST/Type.cpp @@ -75,11 +75,11 @@ const IdentifierInfo* QualType::getBaseTypeIdentifier() const { if (ty->isPointerType() || ty->isReferenceType()) return ty->getPointeeType().getBaseTypeIdentifier(); else if (ty->isRecordType()) - ND = ty->getAs<RecordType>()->getDecl(); + ND = ty->castAs<RecordType>()->getDecl(); else if (ty->isEnumeralType()) - ND = ty->getAs<EnumType>()->getDecl(); + ND = ty->castAs<EnumType>()->getDecl(); else if (ty->getTypeClass() == Type::Typedef) - ND = ty->getAs<TypedefType>()->getDecl(); + ND = ty->castAs<TypedefType>()->getDecl(); else if (ty->isArrayType()) return ty->castAsArrayTypeUnsafe()-> getElementType().getBaseTypeIdentifier(); |