[SR-11892] Suggest inheriting NSObject
instead of providing stubs for NSObjectProtocol
#54309
Labels
NSObject
instead of providing stubs for NSObjectProtocol
#54309
Additional Detail from JIRA
md5: 645c7c0cbdfebd74c38dc291c668bb62
Issue Description:
https://twitter.com/peres/status/1201904431207456769
If you try to make a type conform to NSObjectProtocol, the compiler will helpfully offer to generate stubs for you…but there are a ton of requirements, and there's no practical way to implement many of them in Swift. It would be more helpful to suggest making the class inherit `NSObject` instead (if it doesn't already have a base class), since that's generally a practical requirement to get acceptable `NSObjectProtocol` implementations anyway.
The text was updated successfully, but these errors were encountered: