> On Jan 30, 2017, at 12:36 PM, Robert Widmann via swift-evolution 
> <[email protected]> wrote:
> 
> This seems to contradict Swift’s goal of being safe by default 
> <https://swift.org/about/>, no?

IIUC, it wouldn’t contradict that goal if the compiler could guarantee that 
everything still gets initialized. I don’t know how that would work with 
classes that have private/fileprivate properties, though. If you’re subclassing 
something from the same project, the compiler could just look, but seeing as 
how exposing those things would kinda defeat the purpose, I don’t think there’s 
an existing mechanism for it to check 3rd party classes. Maybe we could add a 
flag to classes’ binary format indicating whether it’s possible for the 
compiler to infer if super.init() can be safely skipped?

I don’t have a opinion yet on whether this proposal is a good idea… I’m just 
commenting on (my understanding of) Swift’s safety goals.

- Dave Sweeris
_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to