[swift-evolution] Optional comparison operators
Dave Abrahams
dabrahams at apple.com
Tue Jul 12 19:12:34 CDT 2016
on Tue Jul 12 2016, Chris Lattner <swift-evolution at swift.org> wrote:
>> On Jul 11, 2016, at 11:22 PM, Mark Lacey <mark.lacey at apple.com> wrote:
>>
>>>
>>> If this is relating to implementation details of the standard
>>> library, then it should be omitted from the proposal. The
>
>>> following paragraph also makes sense to revise if you drop this:
>>> "Additionally the standard library has approximately a half a dozen
>>> locations where optionals are compared to non-optional values which
>>> will need to be updated to explicitly cast one operand to an
>>> optional.”
>>>
>>
>> Thanks for the great feedback. I have most of it addressed, but I’m
>> not sure what you’re referring to with “If this is relating to
>> implementation details of the standard library…”? Do you mean the
>> functions I called out that need to be added?
>>
>> I can remove that, but I thought it was worth calling out despite
>> the fact that they are just overloads. If it’s not necessary to do
>> so, I’ll delete that section (although there aren’t many details
>> left in the “Detailed design” at that point).
>
> I’m referring to this part of the proposal:
>
> "Additionally the standard library has approximately a half a dozen
> locations where optionals are compared to non-optional values which
> will need to be updated to explicitly cast one operand to an
> optional.”
>
> I’m just saying that the internal implementation details of the
> standard library are typically considered part of an evolution
> proposal, only the public API impact.
Right; it's the standard library team's job to suffer for the sake of
our users :-). If improving our APIs means work for us, that's no
problem.
That said, actually *implementing and testing* the proposal proves that
it is implementable, and observing its impact on the standard library
can provide useful information about the likely impact on user code. A
pull request supporting any proposal is always appreciated and makes it
easier to accept.
hint-hint-ly y'rs,
--
Dave
More information about the swift-evolution
mailing list