<html><body><div id="edo-message"><div>I was a little confused by this - I believe the previous proposal involved replacing final (and assuming it unless opened).</div><div><br></div><div>I do not support "sealed". -1000 from me. I would absolutely holeheartedly support "final" by default; it's not very different to turning WMO on by default - and actually since we did so, classes you don't open up or internally subclass are implicitly final already, so it fits really nicely.</div><div><br></div><div>I don't want there to be both "sealed by default" and "final" in the language describing the same concept; it's confusing, users won't know immediately which is the standard behaviour. I also don't agree with a "final outside module" (sealed) attribute - it's an ugly compromise because we don't want to anger subclassers, but at the same time we clearly arent convinced by their arguments. This is a cowardly concession which makes the language uglier and less easy to reason about, just so complainers will keep quiet<span style="-webkit-tap-highlight-color: transparent; -webkit-text-size-adjust: auto;">.</span></div><div><br></div><div>If the core team believes subclassability should be explicit, make it explicit everywhere. It honestly doesn't come up too often, and when it does tacking an 'internal(open)' &nbsp;isn't the hardest thing to make people do. It would make all code involving classes much easier to locally reason about - "is this class overridden? By whom? How much freedom do I have to change things? Oh, all of the subclasses are internal? That's great, change away..."</div><div><br></div><div>We don't have header files any more. Our source should be maximally self-documenting; not just for the compiler and optimisation potential, but for human beings too.&nbsp;</div><div><br></div><div>Karl</div><div><br></div><div><br><div style="font-family: 'Helvetica Neue','Helvetica',Helvetica,Arial,sans-serif;font:'-apple-system-body';">Sent from my new <a href="https://itunes.apple.com/app/apple-store/id922793622?pt=814382&amp;mt=8&amp;ct=my_new_email">Email</a></div></div></div><div id="edo-original"><div><br><br><blockquote type="cite" style="margin:1ex 0 0 0;border-left:1px #ccc solid;padding-left:0.5ex;"><div>On Jul 18, 2016 at 8:57 PM, &lt;<a href="mailto:swift-evolution@swift.org">Leonardo Pessoa via swift-evolution</a>&gt; wrote:<br><br></div><div><pre>Nevin/Garth, please remember final and sealed are two different<br>concepts: final prevents anyone from subclassing/overriding while<br>sealed prevents from subclassing/overriding *outside* the module they<br>are declared. Thus final is not the same as sealed.<br><br>L<br><br><br>On 18 July 2016 at 15:45, Nevin Brackett-Rozinsky via swift-evolution<br>&lt;<a dir="ltr" href="mailto:swift-evolution@swift.org" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="2">swift-evolution@swift.org</a>&gt; wrote:<br>&gt; Garth makes an excellent point. Károly is correct that we can already<br>&gt; achieve “sealed” by making a `final` member call through to an `internal`<br>&gt; one.<br>&gt;<br>&gt; Therefore, it seem clear that “open” should only be applicable to classes,<br>&gt; not to members. This should simplify the proposal nicely.<br>&gt;<br>&gt; Nevin<br>&gt;<br>&gt;<br>&gt; On Mon, Jul 18, 2016 at 2:39 PM, Garth Snyder via swift-evolution<br>&gt; &lt;<a dir="ltr" href="mailto:swift-evolution@swift.org" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="4">swift-evolution@swift.org</a>&gt; wrote:<br>&gt;&gt;<br>&gt;&gt; &gt; Károly wrote: I suggest we change the proposal to remove the implicit<br>&gt;&gt; &gt; "sealed" level of public member overridability, and support only "open" or<br>&gt;&gt; &gt; "final" class members. For members, "open" should mean the opposite of<br>&gt;&gt; &gt; "final", with no levels in between. Member-level openness should be entirely<br>&gt;&gt; &gt; independent of visibility; so it should be possible to say "internal open"<br>&gt;&gt; &gt; to mean an internally overridable member that's not at all visible outside<br>&gt;&gt; &gt; the module -- the same as today's default.<br>&gt;&gt;<br>&gt;&gt; What is the distinction between this approach and simply omitting the<br>&gt;&gt; ability to apply the “open” keyword to anything but a class?<br>&gt;&gt;<br>&gt;&gt; The current behavior is (IIUC) that you cannot override a superclass’s<br>&gt;&gt; final method. Aside from that, you can override any other method that’s<br>&gt;&gt; visible to you, wherever you stand with regard to the superclass’s origin.<br>&gt;&gt; If there’s no sealed status for members, why is any change to member<br>&gt;&gt; annotations needed at all?<br>&gt;&gt;<br>&gt;&gt; Garth<br>&gt;&gt;<br>&gt;&gt; _______________________________________________<br>&gt;&gt; swift-evolution mailing list<br>&gt;&gt; <a dir="ltr" href="mailto:swift-evolution@swift.org" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="6">swift-evolution@swift.org</a><br>&gt;&gt; <a dir="ltr" href="https://lists.swift.org/mailman/listinfo/swift-evolution" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="7">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br>&gt;<br>&gt;<br>&gt;<br>&gt; _______________________________________________<br>&gt; swift-evolution mailing list<br>&gt; <a dir="ltr" href="mailto:swift-evolution@swift.org" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="8">swift-evolution@swift.org</a><br>&gt; <a dir="ltr" href="https://lists.swift.org/mailman/listinfo/swift-evolution" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="9">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br>&gt;<br>_______________________________________________<br>swift-evolution mailing <a dir="ltr" href="mailto:listswift-evolution@swift.orghttps" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="10">list</a><br><a dir="ltr" href="mailto:listswift-evolution@swift.orghttps" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="10">swift-evolution@swift.org</a><br><a dir="ltr" href="mailto:listswift-evolution@swift.orghttps" x-apple-data-detectors="true" x-apple-data-detectors-type="link" x-apple-data-detectors-result="10">https</a>://lists.swift.org/mailman/listinfo/swift-evolution<br></pre></div></blockquote></div></div></body></html>