[swift-evolution] [Draft] Abolish IUO type

Chris Willmore cwillmore at apple.com
Wed Mar 16 23:03:43 CDT 2016


> On Mar 16, 2016, at 6:44 PM, Brent Royal-Gordon <brent at architechies.com> wrote:
> 
>> Let me play devil’s advocate: why not just get rid of implicit unwrapping entirely?
>> 
>> Apple’s Objective-C APIs have had plenty of time to be audited by now.
> 
> Two reasons:
> 
> 1. There are still a number of obscure Apple frameworks which have not been audited.
> 
> 2. Not all imported code comes from Apple frameworks. In particular, Linux is a whole new world of unaudited—and frankly, probably never-going-to-be-audited in large part—code. Each time Swift moves to a new platform, it will need implicit unwrapping again for a few years while the major libraries get audited. Burning your ships is only a good motivational strategy if you don't need to go anywhere else.

These are excellent points, Brent. Many, many Apple Objective-C APIs have not yet been audited for nullability, and IUOs remain a useful tool until they are — that’s the main reason we’re not proposing getting rid of them entirely. I hadn’t considered Linux but that’s a compelling argument as well.
— Chris W.


More information about the swift-evolution mailing list