Let me try to redirect this conversation, if I may.<br><br>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.<br><br>So, little point in having a vote as to whether one is in favor of OrderedSet or not. In my view, the questions to be answered are:<br><br>For the core team–<br><br>* Is it still the plan to offer value types postponed from SE-0069 as a future addition to Foundation?<br><br>* If so, is that a priority in the Swift 5 timeframe, and how can the community help to bring about this addition?<br><br>If not, for the whole community–<br><br>* Is it wise to implement such a type in the standard library? Should we simply bring over the native implementation from Swift Package Manager? What are the implications for bridging?<br><div class="gmail_quote"><div dir="ltr">On Fri, Jun 9, 2017 at 11:38 Remy Demarest via swift-evolution <<a href="mailto:swift-evolution@swift.org">swift-evolution@swift.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">+1 for ordered set and dictionary, and please add ordered dictionary in ObjC as well.<br><br><div id="m_8126729879696255769AppleMailSignature">Envoyé de mon iPhone</div></div><div dir="auto"><div><br>Le 9 juin 2017 à 03:11, Robert Bennett via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>> a écrit :<br><br></div><blockquote type="cite"><div><div></div><div>+1, and would also like to see OrderedDictionary as well.</div><div><br>On Jun 9, 2017, at 12:50 AM, Jeff Kelley via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>> wrote:<br><br></div><blockquote type="cite"><div>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.<div><br></div><div><br><div>
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-variant-east-asian:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-variant-east-asian:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-variant-east-asian:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><div style="color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-variant-east-asian:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><span class="m_8126729879696255769Apple-style-span" style="border-collapse:separate;color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-variant-east-asian:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;border-spacing:0px"><div style="word-wrap:break-word"><div>Jeff Kelley</div><div><br></div><div><a href="mailto:SlaunchaMan@gmail.com" target="_blank">SlaunchaMan@gmail.com</a> | <a href="https://twitter.com/SlaunchaMan" target="_blank">@SlaunchaMan</a> | <a href="http://jeffkelley.org" target="_blank">jeffkelley.org</a></div></div></span></div></div></div></div></div>
</div>
<br><div><blockquote type="cite"><div>On Jun 7, 2017, at 2:10 PM, Maik Koslowski via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>> wrote:</div><br class="m_8126729879696255769Apple-interchange-newline"><div><div dir="auto"><div><span></span></div><div>Hello,<br><div><div><div style="word-wrap:break-word"><div dir="auto" style="word-wrap:break-word"><div dir="auto" style="word-wrap:break-word"><div dir="auto" style="word-wrap:break-word"><div><br></div><div>in the past there have been a few requests for an OrderedSet implementation in Swift. In the proposal <a href="https://github.com/apple/swift-evolution/blob/master/proposals/0069-swift-mutability-for-foundation.md" target="_blank">https://github.com/apple/swift-evolution/blob/master/proposals/0069-swift-mutability-for-foundation.md</a> was mentioned that the OrderedSet will be considered for the feature.</div><div><br></div><div>However, since then there were a few discussions on OrderedSet but it doesn’t get much attention and there wasn’t any comment about it from the swift team.</div><div><br></div><div>I want to bring up some points, why an OrderedSet is needed in the base library.</div><div><br></div><div>1. CoreData is probably the most obvious place where people would use an ordered set. Especially when working with large amounts of data, presorting can save a lot of time and battery life. If a bridgeable ordered set was part of the standard library we could use a ordered set in swift without having to use the NSOrderedSet from objective c. Which would be pretty nice in my opinion. Even when using a NSOrderedSet we couldn’t have a generic version of it.</div><div><br></div><div>2. A shared datamodel between App and Server. One main advantage of having web servers written in Swift is that we can share code between the server and the app. For servers performance does matter a lot, since they are usually working with much more data than apps. Databases are represented as sets and fetching sorted data from the database can be represented as an ordered set. However, since we don’t have ordered sets we have to choose either a normal set or an array. Sets don’t have an order and arrays can contain the same object multiple times, which makes them both a less suitable choice.</div><div><br></div><div>3. Swift has the potential to be used for education. There is a lot of support, for example the playground app on iPad. When it comes to the theory behind data structures and algorithms or to the theory of computation a defined order plays an important role.</div><div><br></div><div>The biggest issue is that we always have to copy data from a set into an array to have it in a sorted order with losing the safety of uniqueness. Which is not suitable for a safe and performance oriented programming language at all.</div><div><br></div><div>Last but not least, it fits in the goals of Swift 4 stage 2 and an ordered set can be found in other popular programming languages, too.</div><div><br></div><div>What do you think?</div><div><br></div><div>Best regards,</div><div><br></div><div>Maik</div></div></div></div></div></div></div><br></div></div>_______________________________________________<br>swift-evolution mailing list<br><a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a><br><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br></div></blockquote></div><br></div></div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>swift-evolution mailing list</span><br><span><a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a></span><br><span><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a></span><br></div></blockquote></div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>swift-evolution mailing list</span><br><span><a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a></span><br><span><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a></span><br></div></blockquote></div>_______________________________________________<br>
swift-evolution mailing list<br>
<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a><br>
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br>
</blockquote></div>