[PATCH] D36790: [ObjC] Messages to 'self' in class methods that return 'instancetype' should use the pointer to the class as the result type of the message

Alex Lorenz via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 24 17:31:48 PDT 2017


arphaman updated this revision to Diff 120157.
arphaman retitled this revision from "[ObjC] Messages to 'self' in class methods should use class method dispatch to avoid multiple method ambiguities" to "[ObjC] Messages to 'self' in class methods that return 'instancetype' should use the pointer to the class as the result type of the message".
arphaman added a comment.

I changed the approach for this patch. Now, instead of using class method dispatch Clang instead adjusts the result type of the message sends to methods that return `instancetype` with `self` receivers in class methods.


Repository:
  rL LLVM

https://reviews.llvm.org/D36790

Files:
  include/clang/Sema/Sema.h
  lib/Sema/SemaExprObjC.cpp
  test/SemaObjC/multiple-method-names-in-class-self.m

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D36790.120157.patch
Type: text/x-patch
Size: 8605 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171025/868b99d2/attachment.bin>


More information about the cfe-commits mailing list