[cfe-commits] r58380 - /cfe/trunk/Driver/RewriteObjC.cpp
Steve Naroff
snaroff at apple.com
Wed Oct 29 07:49:47 PDT 2008
Author: snaroff
Date: Wed Oct 29 09:49:46 2008
New Revision: 58380
URL: http://llvm.org/viewvc/llvm-project?rev=58380&view=rev
Log:
Make sure internally synthesized block pointer types are converted before pretty printing.
Modified:
cfe/trunk/Driver/RewriteObjC.cpp
Modified: cfe/trunk/Driver/RewriteObjC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Driver/RewriteObjC.cpp?rev=58380&r1=58379&r2=58380&view=diff
==============================================================================
--- cfe/trunk/Driver/RewriteObjC.cpp (original)
+++ cfe/trunk/Driver/RewriteObjC.cpp Wed Oct 29 09:49:46 2008
@@ -2180,6 +2180,11 @@
QualType t = mDecl->getParamDecl(i)->getType()->isObjCQualifiedIdType()
? Context->getObjCIdType()
: mDecl->getParamDecl(i)->getType();
+ // Make sure we convert "t (^)(...)" to "t (*)(...)".
+ if (isBlockPointerType(t)) {
+ const BlockPointerType *BPT = t->getAsBlockPointerType();
+ t = Context->getPointerType(BPT->getPointeeType());
+ }
ArgTypes.push_back(t);
}
returnType = mDecl->getResultType()->isObjCQualifiedIdType()
More information about the cfe-commits
mailing list