diff options
author | John McCall <rjmccall@apple.com> | 2010-12-24 02:08:15 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-12-24 02:08:15 +0000 |
commit | 53fa71476d0539b031a8f91232607f5ca8f182e5 (patch) | |
tree | 9e6d370da16c00a54a4b7f8ad66553458cedf899 /clang/lib/AST/ASTContext.cpp | |
parent | b4d271ef46bde4815c3ca3363779645ce3513811 (diff) | |
download | bcm5719-llvm-53fa71476d0539b031a8f91232607f5ca8f182e5.tar.gz bcm5719-llvm-53fa71476d0539b031a8f91232607f5ca8f182e5.zip |
Refactor how we collect attributes during parsing, and add slots for attributes
on array and function declarators. This is pretty far from complete, and I'll
revisit it later if someone doesn't beat me to it.
llvm-svn: 122535
Diffstat (limited to 'clang/lib/AST/ASTContext.cpp')
-rw-r--r-- | clang/lib/AST/ASTContext.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp index eaf222cafad..b145683ce5e 100644 --- a/clang/lib/AST/ASTContext.cpp +++ b/clang/lib/AST/ASTContext.cpp @@ -1119,8 +1119,8 @@ QualType ASTContext::getObjCGCQualType(QualType T, if (CanT.getObjCGCAttr() == GCAttr) return T; - if (T->isPointerType()) { - QualType Pointee = T->getAs<PointerType>()->getPointeeType(); + if (const PointerType *ptr = T->getAs<PointerType>()) { + QualType Pointee = ptr->getPointeeType(); if (Pointee->isAnyPointerType()) { QualType ResultType = getObjCGCQualType(Pointee, GCAttr); return getPointerType(ResultType); |