[swift-evolution] (core library) modern URL types

Taylor Swift kelvin13ma at gmail.com
Thu Sep 21 12:52:43 CDT 2017

great work! it looks like there is quite a lot of duplicated work going on
here though which is unfortunate. how do we reconcile these 2

On Thu, Sep 21, 2017 at 12:16 PM, Aleksey Mashanov <
aleksey.mashanov at gmail.com> wrote:

> I have an alternative implementation of a URI (a superset of URL). It is
> quite ready to use but still requires some polishing and adding of
> additional specific URI schemes.
> It is designed primarily for server side usage but can be useful on a
> client too. The main goals of the design is correctness (according to
> RFC3986 and RFC7230) and efficiency.
> You can take a look at it here: https://github.com/my-mail-ru/swift-URI
> 2017-08-21 7:38 GMT+03:00 Taylor Swift via swift-evolution <
> swift-evolution at swift.org>:
>> Okay so a few days ago there was a discussion
>> <https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20170814/038923.html>
>> about getting pure swift file system support into Foundation or another
>> core library, and in my opinion, doing this requires a total overhaul of
>> the `URL` type (which is currently little more than a wrapper for
>> NSURL), so I’ve just started a pure Swift URL library project at <
>> https://github.com/kelvin13/url>.
>> The library’s parsing and validation core (~1K loc pure swift) is already
>> in place and functional; the goal is to eventually support all of the
>> Foundation URL functionality.
>> The new `URL` type is implemented as a value type with utf8 storage
>> backed by an array buffer. The URLs are just 56 bytes long each, so they
>> should be able to fit into cache lines. (NSURL by comparison is over 128
>> bytes in size; it’s only saved by the fact that the thing is passed as a
>> reference type.)
>> As I said, this is still really early on and not a mature library at all
>> but everyone is invited to observe, provide feedback, or contribute!
>> _______________________________________________
>> 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/20170921/f1c65353/attachment.html>

More information about the swift-evolution mailing list