<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="">Am 28.08.2016 um 05:34 schrieb Kevin Ballard via swift-evolution <<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>>:</div><br class="Apple-interchange-newline"><div class=""><div class=""><blockquote type="cite" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: 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="">My biggest issue with Optional conforming to Comparable is that while a default implementation may sometimes be useful, it may not necessarily be the one you want.<br class=""></div></blockquote><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: 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=""><br class=""></div><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: 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="">Isn't that true for almost everything?</div></div></div></blockquote></div><div class="">That reminds me on a feature that has been discussed and added before:</div><div class="">Making tuples conform to Comparable (<a href="https://github.com/apple/swift-evolution/blob/master/proposals/0015-tuple-comparison-operators.md" class="">https://github.com/apple/swift-evolution/blob/master/proposals/0015-tuple-comparison-operators.md</a>)</div><div class="">The implementation doesn't hurt me, but imho it's use is very limited as well.</div><div class=""><br class=""></div><div class="">As for comparing optionals, my preferred result would be an Optional<Bool>:</div><div class="">if (value < 5) ?? true {…</div><div class="">It makes no assumptions on the order, is clear and also concise.</div><div class=""><br class=""></div><div class="">Tino</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class="">There was a sketch of this posted to swift-evolution several weeks ago, but I don’t have a link offhand.</blockquote></div><div class="">That, on the other hand, reminds me on the discussion about switching to another platform, because the mailing list sucks. I couldn't find a link to that one either (guess why ;-)</div><div class=""><br class=""></div><div class=""><br class=""></div></body></html>