[swift-evolution] [Review] SE-0067: Enhanced Floating Point Protocols

Dany St-Amant dsa.mls at icloud.com
Fri Apr 22 05:45:54 CDT 2016

> Le 20 avr. 2016 à 16:07, Dave Abrahams via swift-evolution <swift-evolution at swift.org> a écrit :
>> on Wed Apr 20 2016, Stephen Canon <swift-evolution at swift.org> wrote:
>> Comments inline.
>>> On Apr 20, 2016, at 12:04 PM, Xiaodi Wu <xiaodi.wu at gmail.com> wrote:
>>> Also potentially useful (actually, definitely useful in implementing
>>> floating point strides) would be the properties `maxExactInteger`
>>> (and, I suppose, a corresponding `minExactInteger`).
>> An early draft of the protocol had these.  Naming this property is
>> *hard*, because every floating-point value larger than
>> `maxExactInteger` is … an exact integer.  If you want to be
>> unambiguously precise, you end up with something horrible.  Ultimately
>> I punted on this issue, but I would definitely support adding it in
>> the future if an appropriate name can be found, or if a compelling use
>> case arises (I don’t think it’s actually needed for implementing
>> strides).
> Isn't this really maxResultOfAdding1?

Would a more generic:
make sense?


More information about the swift-evolution mailing list