<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 class="">By imposing that kind of separation you leave an entire class of generic and structural programming patterns off the table. &nbsp;An enumeration is not just an enumeration of constants, it is an enumeration of <i class="">data, </i>and data takes far more useful forms than just bitfields - similarly when it does have that form it fits precisely into the form of an enum with no cases? &nbsp;Why artificially separate the two concepts when they’re clearly one and the same?</div><div class=""><br class=""></div><div class="">~Robert Widmann</div><br class=""><div><blockquote type="cite" class=""><div class="">On Oct 10, 2016, at 2:24 PM, Kevin Nattinger via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">I agree wholeheartedly. An enum case should be a compile-time constant. &nbsp;IMO, “enums” with associated values should properly be a separate entity, called “union” as that’s essentially what they are. <br class=""><br class=""><blockquote type="cite" class="">On Oct 10, 2016, at 10:31 AM, Kenny Leung via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:<br class=""><br class="">This is the way Java enumerations work. <br class=""><br class=""><a href="https://docs.oracle.com/javase/tutorial/java/javaOO/enum.html" class="">https://docs.oracle.com/javase/tutorial/java/javaOO/enum.html</a><br class=""><br class="">I think it is a good model, and I think Swift enumerations should also work the same way.<br class=""><br class="">An enumeration is a finite set of things. It’s really inconvenient to have to limit those things to have only a single attribute.<br class=""><br class="">-Kenny<br class=""><br class=""><br class="">_______________________________________________<br class="">swift-evolution mailing list<br class="">swift-evolution@swift.org<br class="">https://lists.swift.org/mailman/listinfo/swift-evolution<br class=""></blockquote><br class="">_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class="">https://lists.swift.org/mailman/listinfo/swift-evolution<br class=""></div></div></blockquote></div><br class=""></body></html>