[swift-evolution] Final by default for classes and methods

Greg Titus greg at omnigroup.com
Mon Dec 21 12:39:59 CST 2015


> On Dec 21, 2015, at 10:04 AM, Dave Abrahams via swift-evolution <swift-evolution at swift.org> wrote:
> 
> In my considerable experience with C++, that is not at all where we are today.  Increasingly, C++ is becoming seen as a language for high-performance computing, and people working in that area learn that they don't want to pay for virtual dispatch when they don't have to.  It is true that for some of them, reflexive use of OOP is hard to shake, but they do learn eventually.  Note also that Swift is really the second major language to take value semantics seriously.  The first was C++.
> 

I love those parts of Swift. Generics and value-type structs and high performance from static binding. But I also love UIKit and AppKit and the loosey-goosey but highly productive Objective-C style of dynamic binding and subclassability everywhere.

There’s a great balance here in Swift between ‘struct’ and ‘class’ and two very different styles of programming, and in my opinion, this proposal is trying to extend what ARE benefits of one half of the language in a way that is likely to wreck the other half of the language. Which is why I’m -1.

	- Greg


More information about the swift-evolution mailing list