Re: [swift-evolution] Introduction of OrderedSet

2017-06-13 Thread Douglas Gregor via swift-evolution
Sent from my iPhone > On Jun 13, 2017, at 6:05 AM, Maik Koslowski wrote: > > It’s definitely more effort needed than i thought at first. I can create an > API suggestion, but that will take a while. Since this will happen in Swift 5 > or later, we will have enough

Re: [swift-evolution] Introduction of OrderedSet

2017-06-13 Thread Maik Koslowski via swift-evolution
It’s definitely more effort needed than i thought at first. I can create an API suggestion, but that will take a while. Since this will happen in Swift 5 or later, we will have enough time anyway. Does it make sense to create a proposal on GitHub or should I wait at least for Swift 5 since

Re: [swift-evolution] Introduction of OrderedSet

2017-06-12 Thread Douglas Gregor via swift-evolution
> On Jun 10, 2017, at 8:42 AM, Tony Parker wrote: > > This is still something I want to do, but I suspect it will require some > coordination work with the NSOrderedSet ref type in Foundation. > > Also, as Doug says, there is a larger question too of how we make

Re: [swift-evolution] Introduction of OrderedSet

2017-06-12 Thread Maik Koslowski via swift-evolution
Thanks for your replies. Something like an OrderedSet should always be in the standard library to serve the best possible performance and thats why I’m not in favor of a third party implementation. The biggest issue seems to be bridging. I really don’t want to „ignore“ bridging, because

Re: [swift-evolution] Introduction of OrderedSet

2017-06-10 Thread Tony Parker via swift-evolution
This is still something I want to do, but I suspect it will require some coordination work with the NSOrderedSet ref type in Foundation. Also, as Doug says, there is a larger question too of how we make source breaking changes like this in Swift 5 (I think we’re probably out of runway for

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Robert Bennett via swift-evolution
I recall reading that in Python 3.6 they changed the implementation of set and dict to both have better performance *and* maintain insert order for free. I know nothing about the implementation details of this but might it be possible to make a similar change to Swift’s Set and Dictionary, so

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Douglas Gregor via swift-evolution
> On Jun 9, 2017, at 10:19 AM, Xiaodi Wu via swift-evolution > wrote: > > Let me try to redirect this conversation, if I may. > > As far as I can tell, SE-0069 states plainly that the plan of record is to > offer a value type called OrderedSet in Foundation, but

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Xiaodi Wu via swift-evolution
Let me try to redirect this conversation, if I may. As far as I can tell, SE-0069 states plainly that the plan of record is to offer a value type called OrderedSet in Foundation, but resources to design and implement were not then available. So, little point in having a vote as to whether one is

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Gor Gyolchanyan via swift-evolution
This sounds awesome to me, except I'd take it a bit further and bring this idea to its logical conclusion: creating concrete type subtypes. Take, for example the CGFloat, which is a struct, that's essentially a subtype of Double. Seems like what you actually want is to create a subtype of

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Remy Demarest via swift-evolution
+1 for ordered set and dictionary, and please add ordered dictionary in ObjC as well. Envoyé de mon iPhone > Le 9 juin 2017 à 03:11, Robert Bennett via swift-evolution > a écrit : > > +1, and would also like to see OrderedDictionary as well. > >> On Jun 9, 2017,

Re: [swift-evolution] Introduction of OrderedSet

2017-06-09 Thread Robert Bennett via swift-evolution
+1, and would also like to see OrderedDictionary as well. > On Jun 9, 2017, at 12:50 AM, Jeff Kelley via swift-evolution > wrote: > > I would be in favor of it; there have been a few times (including Core Data, > as you mentioned) where I would have used it had it

Re: [swift-evolution] Introduction of OrderedSet

2017-06-08 Thread Jeff Kelley via swift-evolution
I would be in favor of it; there have been a few times (including Core Data, as you mentioned) where I would have used it had it been available. Jeff Kelley slauncha...@gmail.com | @SlaunchaMan | jeffkelley.org > On Jun 7, 2017, at

[swift-evolution] Introduction of OrderedSet

2017-06-08 Thread Maik Koslowski via swift-evolution
Hello, in the past there have been a few requests for an OrderedSet implementation in Swift. In the proposal https://github.com/apple/swift-evolution/blob/master/proposals/0069-swift-mutability-for-foundation.md was mentioned that the OrderedSet will be considered for the feature. However,