<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div><blockquote type="cite" class=""><div class=""><div dir="auto" class=""><div class=""><div style="margin: 0px; font-size: 12px; line-height: normal; font-family: Helvetica; -webkit-text-stroke-color: rgb(0, 0, 0); -webkit-text-stroke-width: initial;" class=""><span style="font-size: 12pt; -webkit-font-kerning: none;" class="">Enum cases _feel_ like separately defined, but tightly related structs because each case can have distinct associated values. They have special privileges that a family of structs doesn't have, like `self = .otherCase`. Enums are really awesome.</span></div></div></div></div></blockquote><div><br class=""></div><div><musings></div><div><br class=""></div>I think this is the primary difference between a “tagged union” and a Swift enum - I might have a union of several discrete types in other languages, but in swift it is actually an enumeration of cases within a single type. The individual cases are not types.</div><div><br class=""></div><div>This was actually one of the reasons that drove case labels and static values to stylistically change to lowercase in Swift 3 - to avoid building a misconception of enum cases being distinct types.</div><div><br class=""></div><div>I’ve wanted this feature in the past as well, but wonder if at some point encouraging support for a distinct union of types makes more sense than expanding enum - say, a closed protocol only allowing implementation by specific types declared within its module. </div><div><br class=""></div><div>-DW</div><div><br class=""></div></body></html>