<html><head><style>body{font-family:Helvetica,Arial;font-size:13px}</style></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div><blockquote type="cite" class="clean_bq" style="font-family: Helvetica, Arial; font-size: 13px; 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;"><span><div><div>&gt; Optional.map and Array.map do different things, and unifying them seems harmful.<br><br>They actually don’t do different things. Optional can be thought of as an array of zero or one elements; from that point of view, operations like `map` and `flatMap` which are supported on both actually do the same thing.</div></div></span></blockquote></div><p><br></p><p>This discussion convinces me to vote -1 for the HKTs in standard library.&nbsp;</p><p><br></p><p>For the programmers without functional programming background HKTs gonna be misleading and non-readable. A thousand similar analogies: "&lt;OneMonad&gt; can be seen as &lt;OtherMonad&gt;" will need to be made. Those analogies are gonna break (for example, how would one explain monad transformers in those terms?) and lead to even more confusion.&nbsp;</p><p><br></p><p>As long as the underlying theory is not widely adopted, I think HKTs should be provided by third-party libraries (like swiftz). Swift should just provide generics sophisticated enough to express the those concepts. Scala language uses similar approach (no HKTs in standard library, great generics) with success (scalaz, shapeless libraries).</p><p><br></p><p><br></p><p>Krzysztof</p><p><br></p><div><blockquote type="cite" class="clean_bq" style="font-family: Helvetica, Arial; font-size: 13px; 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;"><span><div><div><br><br>--<span class="Apple-converted-space">&nbsp;</span><br>Brent Royal-Gordon<br>Architechies<br><br>_______________________________________________<br>swift-evolution mailing list<br>swift-evolution@swift.org<br>https://lists.swift.org/mailman/listinfo/swift-evolution<br></div></div></span></blockquote></div></body></html>