[swift-evolution] [Pitch] Changing NSObject dispatch behavior

Joe Groff jgroff at apple.com
Thu Dec 15 16:10:31 CST 2016

> On Dec 15, 2016, at 12:51 PM, Michael Ilseman via swift-evolution <swift-evolution at swift.org> wrote:
> 	• NSObject extensions use message dispatch
> Is this also true of extensions to native Swift subclasses of NSObject? I would assume that they would be static dispatch like any other method in an extension of a native Swift class or subclass.

Extensions use objc_msgSend dispatch only because they can't be in the main vtable, since an extension may be defined in a separate compilation unit, and we haven't implemented a Swift-native equivalent to msgSend that handles Swift's calling convention variants.


More information about the swift-evolution mailing list