<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="">Implied in using the &nbsp;“then", if…then…else would aways require “else" when using “then” similar to how “guard" requires “else”. This &nbsp;will help to make the difference between statements and expressions clear.<div class=""><br class=""></div><div class="">let x = If cond then X else Y</div><div class=""><br class=""></div><div class="">is the full form, where “else" can not be omitted.&nbsp;</div><div class=""><br class=""></div><div><blockquote type="cite" class=""><div class="">On Dec 12, 2015, at 12:59 PM, Paul Ossenbruggen &lt;<a href="mailto:possen@gmail.com" class="">possen@gmail.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><br class=""></div><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Dec 12, 2015, at 12:37 PM, Andrey Tarantsov 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=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">1. I would really hate to explain to someone when <b class="">if</b> needs a <b class="">then</b> and when it doesn't. That's the sort of inconsistency that shouldn't be added lightly.</div></div></div></blockquote><div class=""><br class=""></div><div class="">agreed definitely want to be careful with that. I think with braces meaning statements that differentiation can be made clear. I would certainly start with statements when describing, just as you usually don’t talk about the ternary operator until later.&nbsp;</div></div><div class=""><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">3. If we can somehow solve all of this, I think I'll be +1 for replacing (A ? B : C) with some sort of (<b class="">if</b> A <b class="">then</b> B <b class="">else</b> C).</div></div></div></blockquote><div class=""><br class=""></div>Yes that would be great.</div><div class=""><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><br class=""></div><div class="">4. Generally, I wonder how hard would it be for all statements to be usable as expressions? Why didn't Swift go that way from the start?</div></div></div></blockquote><div class=""><br class=""></div><div class="">The biggest problem statement is you don’t need to exhaustively specify every outcome:</div><div class=""><br class=""></div><div class="">if cond {</div><div class=""><span class="Apple-tab-span" style="white-space:pre">        </span>print(“hello”)</div><div class="">}</div><div class=""><br class=""></div><div class="">whereas in an expression you have to specify what happens in the else.</div><div class=""><br class=""></div><div class="">let say = if cond then “hello” else “goodbye"</div></div><div class=""><br class=""></div><div class="">unless you go seriously off the deep end:</div><div class=""><br class=""></div><div class="">let say = if cond then “hello”&nbsp;</div><div class=""><br class=""></div><div class="">&nbsp;“say" then becomes an optional, *shudder*</div><div class=""><br class=""></div><div class=""><br class=""></div></div></div></blockquote></div><br class=""></body></html>