diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2015-01-23 19:23:42 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2015-01-23 19:23:42 +0000 |
commit | 9498e79e0db23454a29ec26fa56534d95c02b140 (patch) | |
tree | 3e22d8953c5acac33526bf65083668f67afdba09 /lib/ARCMigrate/ObjCMT.cpp | |
parent | 1c11de013af7eca7496ee631a16d4741e09931f3 (diff) |
Objective-C modernizer. Avoid using property-dot syntax when
receiver type is not valid for property-dot syntz use.
rdar://19381786
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@226927 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/ARCMigrate/ObjCMT.cpp')
-rw-r--r-- | lib/ARCMigrate/ObjCMT.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/ARCMigrate/ObjCMT.cpp b/lib/ARCMigrate/ObjCMT.cpp index 52c424c000..48a4931c20 100644 --- a/lib/ARCMigrate/ObjCMT.cpp +++ b/lib/ARCMigrate/ObjCMT.cpp @@ -245,6 +245,10 @@ namespace { (Msg->getReceiverKind() != ObjCMessageExpr::Instance && Msg->getReceiverKind() != ObjCMessageExpr::SuperInstance)) return false; + if (const Expr *Receiver = Msg->getInstanceReceiver()) + if (Receiver->getType()->isObjCBuiltinType()) + return false; + const ObjCMethodDecl *Method = Msg->getMethodDecl(); if (!Method) return false; |