<div dir="ltr">Garth makes an excellent point. Károly is correct that we can already achieve “sealed” by making a `final` member call through to an `internal` one.<div><br></div><div>Therefore, it seem clear that “open” should only be applicable to classes, not to members. This should simplify the proposal nicely.</div><div><br></div><div>Nevin</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jul 18, 2016 at 2:39 PM, Garth Snyder via swift-evolution <span dir="ltr"><<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">> Károly wrote: I suggest we change the proposal to remove the implicit "sealed" level of public member overridability, and support only "open" or "final" class members. For members, "open" should mean the opposite of "final", with no levels in between. Member-level openness should be entirely independent of visibility; so it should be possible to say "internal open" to mean an internally overridable member that's not at all visible outside the module -- the same as today's default.<br>
<br>
What is the distinction between this approach and simply omitting the ability to apply the “open” keyword to anything but a class?<br>
<br>
The current behavior is (IIUC) that you cannot override a superclass’s final method. Aside from that, you can override any other method that’s visible to you, wherever you stand with regard to the superclass’s origin. If there’s no sealed status for members, why is any change to member annotations needed at all?<br>
<br>
Garth<br>
<div class="HOEnZb"><div class="h5"><br>
_______________________________________________<br>
swift-evolution mailing list<br>
<a href="mailto:swift-evolution@swift.org">swift-evolution@swift.org</a><br>
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br>
</div></div></blockquote></div><br></div>