summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis/FormatString.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2011-06-14 22:56:51 +0000
committerTed Kremenek <kremenek@apple.com>2011-06-14 22:56:51 +0000
commit192ed0b7eebcdf7905f595591496c22ced5a7042 (patch)
tree0c61604a436cace13755e811e3da9b0992df61b1 /clang/lib/Analysis/FormatString.cpp
parentcd7f70e8b5362390d8911fdd41b524ced88ab88c (diff)
downloadbcm5719-llvm-192ed0b7eebcdf7905f595591496c22ced5a7042.tar.gz
bcm5719-llvm-192ed0b7eebcdf7905f595591496c22ced5a7042.zip
[format strings] correctly suggest correct type for '%@' specifiers. Fixes <rdar://problem/9607158>.
llvm-svn: 133024
Diffstat (limited to 'clang/lib/Analysis/FormatString.cpp')
-rw-r--r--clang/lib/Analysis/FormatString.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Analysis/FormatString.cpp b/clang/lib/Analysis/FormatString.cpp
index c1b5ea8a652..be214e0d86d 100644
--- a/clang/lib/Analysis/FormatString.cpp
+++ b/clang/lib/Analysis/FormatString.cpp
@@ -300,7 +300,8 @@ bool ArgTypeResult::matchesType(ASTContext &C, QualType argTy) const {
argTy->isNullPtrType();
case ObjCPointerTy:
- return argTy->getAs<ObjCObjectPointerType>() != NULL;
+ return argTy->getAs<ObjCObjectPointerType>() != NULL ||
+ argTy->getAs<BlockPointerType>() != NULL;
}
// FIXME: Should be unreachable, but Clang is currently emitting
OpenPOWER on IntegriCloud