<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=""><br class=""><div><blockquote type="cite" class=""><div class="">On Dec 4, 2015, at 11:43 AM, J. Cheyo Jimenez <<a href="mailto:cheyo@masters3d.com" class="">cheyo@masters3d.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: 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-stroke-width: 0px;" class=""><div class="">I'd like some feedback from the core team to see if eliminating the ternary operator and replacing it with if-else is even proposal worthy. </div><div class=""><br class=""></div><div class="">Some interesting code in the standard library that uses the ternary operator quite a bit. </div><div class=""><br class=""></div><a href="https://gist.github.com/masters3d/7b0c6f3653368afe4357" class="">https://gist.github.com/masters3d/7b0c6f3653368afe4357</a><br class=""></div></div></blockquote><br class=""></div><div>FWIW, I have no love for the ternary operator (it is totally "bizarre C magic”), but it does solve a problem that Swift currently otherwise has no solution for.</div><div><br class=""></div><div>If you’re interested in pursuing this, then the right path forward is to build a holistic proposal to turn statements (like if and switch) into expressions. This is subtle and requires thought, but is widely desired and if someone were interested in driving the design and implementation, then I’d be interested to see it happen.</div><div><br class=""></div><div>-Chris</div><br class=""></body></html>