r/ObjectiveC • • Feb 23 '20

Objective-C safe downcasting

https://whackylabs.com/objc/swift/2020/02/23/objc-safe-downcasting/
5 Upvotes

16 comments sorted by

View all comments

Show parent comment

2

u/[deleted] Feb 24 '20

What I can say is that a nil object returning nil when a message is sent to it is one of the most contentious issues in Objective-C: meaning, when people are criticizing the language, this is one of the things it gets criticized for. It is notorious for creating bugs that are difficult to track down. What is being suggested here is creating another almost identical issue.

I must be crazy then, this is one of my favorite things about ObjC

2

u/mariox19 Feb 24 '20

I think almost all Objective-C programmers appreciate it. But it's a design tradeoff.