[swift-evolution] TrigonometricFloatingPoint/MathFloatingPoint protocol?

Dave DeLong delong at apple.com
Tue Aug 1 12:09:47 CDT 2017


> On Aug 1, 2017, at 9:14 AM, Taylor Swift via swift-evolution <swift-evolution at swift.org> wrote:
> 
> I’ve noticed from this and older threads that everyone agrees on what core libraries we want, but they never actually get built. Perennial requests seem to be
> 
> - RNG and cryptography library (CryptoSwift could be a good base for this)
> - Generic Math library/Vector library
> - Basic data structures (Tree, Balanced Tree, Heap, Queue, SkipList, graphs, etc)
> - Modern DateTime library

This may not be a popular opinion for the masses, but in reality, Foundation is a modern DateTime library. The core functionality provided by Calendar, Date, TimeZone, Locale, and DateFormatter are world-class APIs.

I suspect that what people are really asking for is simpler API to do things like “get the day of the month from a Date” and such. The proper way to do this seemingly involves more types than you’d think is reasonable, but it’s that way for very good reasons.

I’d encourage people who want to know more about this to go read through http://yourcalendricalfallacyis.com <http://yourcalendricalfallacyis.com/>, and I’d be happy to disabuse anyone of false calendrical notions on a new thread.

Cheers,

Dave

> - Modern String processing toolkit
> - 2D Graphics library (similar to cairo)
> - Windowing/UI library
> 
> I think David Turnbull tried to get something like this started years back but it fizzled out pretty quick, probably because the Swift foss community was much smaller back then. Time to try again?
> 
> On Tue, Aug 1, 2017 at 8:29 AM, Georgios Moschovitis <george.moschovitis at icloud.com <mailto:george.moschovitis at icloud.com>> wrote:
> > That's what's happened with the Server APIs Project
> > https://swift.org/server-apis/ <https://swift.org/server-apis/>
> >
> > I would like to see more of this, and math/BigNum seems like a good candidate.
> >
> > Another is a modern date/time package, standing on the shoulders of
> > https://jcp.org/en/jsr/detail?id=310 <https://jcp.org/en/jsr/detail?id=310> and similar.
> 
> + 1
> 
> I would also love to see standard implementation of Graph data structures, at least some common protocols.
> Dunno why this versatile data structure is not included in standard libraries (similar to Map/Dictionary), Set, etc.
> 
> -g.
> 
> _______________________________________________
> 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/20170801/79d4043c/attachment.html>


More information about the swift-evolution mailing list