<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div><br class=""></div><div><blockquote type="cite" class=""><div class=""><span style="color: rgb(69, 69, 69); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; display: inline !important; float: none;" class="">What I’m proposing is that we introduce a new keyword,<span class="Apple-converted-space">&nbsp;</span></span><i style="color: rgb(69, 69, 69); font-family: Helvetica; font-size: 12px; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">unknown</i><span style="color: rgb(69, 69, 69); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; display: inline !important; float: none;" class=""><span class="Apple-converted-space">&nbsp;</span>(or a better name), that serves as a way to handle cases that aren’t yet known, but not those that are.</span><br style="color: rgb(69, 69, 69); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class=""></div></blockquote></div>Afaics, the best this could do is helping when a compiled library using another, updated library with new cases in a switch — but in the common case, that enum would be used in the source code of an app.<div class="">So, to be useful, you’ll need some sort of version annotation in your source, or the compiler will not be able to tell which cases have been added since you wrote a switch.</div><div class=""><br class=""></div><div class="">Also, I really don’t think that exhaustive switching on „alien“ enums is one of the best features in Swift (of course, that depends on what count you allow for a feature to be one of the best ;-):</div><div class="">At least, I don’t see big harm in the proposal. I haven’t seen many examples of framework-defined enums that are extended, and used in switch-statements in client code.</div></body></html>