<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="">Hi, I have a proposal.<div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #0433ff" class="">enum</span> Foo {</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">&nbsp; <span style="font-variant-ligatures: no-common-ligatures; color: #0433ff" class="">case</span> foo,bar</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">}</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo; min-height: 19px;" class=""><br class=""></div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #0433ff" class="">func</span> test(a:<span style="font-variant-ligatures: no-common-ligatures; color: #3495af" class="">Foo</span>) {</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">&nbsp; // …</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">}</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo; min-height: 19px;" class=""><br class=""></div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo; color: rgb(52, 149, 175);" class="">test<span style="font-variant-ligatures: no-common-ligatures; color: #000000" class="">(.</span>bar<span style="font-variant-ligatures: no-common-ligatures; color: #000000" class="">)</span></div></div><div class=""><span style="font-variant-ligatures: no-common-ligatures; color: #000000" class=""><br class=""></span></div><div class=""><br class=""></div><div class="">If I use an enum only as a parameter of a function, the name of enum &nbsp;is redundant.&nbsp;</div><div class=""><br class=""></div><div class="">so I suggest a compact version like below.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #0433ff" class="">func</span> test(a:[<span style="font-variant-ligatures: no-common-ligatures; color: #3495af" class="">foo</span>|bar]) {</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="color: rgb(0, 0, 0);" class="">&nbsp; </span><font color="#3495af" class="">// ...</font></div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">}</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo; min-height: 19px;" class=""><br class=""></div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #3495af" class="">test</span>(.bar)</div></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class=""><span style="color: rgb(4, 51, 255);" class="">func</span>&nbsp;adjustTemperature(temp:[low|<font color="#3495af" class="">normal</font>|high]) {</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">&nbsp;&nbsp;<font color="#3495af" class="">// ...</font></div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo;" class="">}</div><div style="margin: 0px; font-size: 16px; line-height: normal; font-family: Menlo; min-height: 19px;" class=""><br class=""></div></div><div class=""><span style="font-family: Menlo; font-size: 16px;" class="">adjustTemperature</span><span style="font-family: Menlo; font-size: 16px;" class="">(.high)</span></div><div class=""><span style="font-family: Menlo; font-size: 16px;" class=""><br class=""></span></div><div class=""><span style="font-family: Menlo; font-size: 16px;" class=""><br class=""></span></div><div class=""><span style="font-family: Menlo; font-size: 16px;" class=""><br class=""></span></div><div class=""><span style="font-family: Menlo; font-size: 16px;" class="">I think this is very useful.</span></div><div class=""><font face="Menlo" size="3" class="">What do you think?</font></div><div class=""><font face="Menlo" size="3" class=""><br class=""></font></div></body></html>