[swift-evolution] [Draft][Proposal] Formalized Ordering

Xiaodi Wu xiaodi.wu at gmail.com
Thu Jul 21 21:58:23 CDT 2016


On Thu, Jul 21, 2016 at 8:32 PM, Robert Widmann <rwidmann at apple.com> wrote:

>
> On Jul 21, 2016, at 6:19 PM, Xiaodi Wu <xiaodi.wu at gmail.com> wrote:
>
> This is nice. Is `areSame()` being proposed because static `==` is the
> status quo and you're trying to make the point that `==` in the future need
> not guarantee the same semantics?
>
>
> Yep!  Equivalence and equality are strictly very different things.
>
>
> Nit: I think the more common term in stdlib would be `areEquivalent()`. Do
> you think `same` in that context (independent of the word "ordering") might
> erroneously suggest identity?
>
>
> There is room for improvement here.  Keep ‘em coming.
>

Well, since you asked...
Wikipedia reminds me that a ~ b is an appropriate mathematical notation for
equivalence of a and b. We probably wouldn't want to confuse things with
bitwise not, but in the grand tradition of reduplicating to form operators
from their mathematical counterparts, what about infix operator `~~`? [In a
few minutes, I might find this to be a terrible idea.]

On Thu, Jul 21, 2016 at 8:11 PM, Robert Widmann via swift-evolution <
> swift-evolution at swift.org> wrote:
>
>> Hello Swift Community,
>>
>> Harlan Haskins, Jaden Geller, and I have been working on a proposal to
>> clean up the semantics of ordering relations in the standard library.  We
>> have a draft that you can get as a gist.
>> <https://gist.github.com/CodaFi/f0347bd37f1c407bf7ea0c429ead380e>  Any
>> feedback you might have about this proposal helps - though please keeps
>> your comments on Swift-Evolution and not on the gist.
>>
>> Cheers,
>>
>> ~Robert Widmann
>>
>>
>>
>>
>>
>> _______________________________________________
>> swift-evolution mailing list
>> swift-evolution at swift.org
>> https://lists.swift.org/mailman/listinfo/swift-evolution
>>
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160721/cc7c6847/attachment.html>


More information about the swift-evolution mailing list