<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 3, 2017, at 2:39 PM, Jens Persson <<a href="mailto:jens@bitcycle.com" class="">jens@bitcycle.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class="">Would this help sorting out the behavior of typealiases in constrained extensions?</div></div></div></blockquote><div><br class=""></div>Sadly, no.</div><div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class=""><br class=""></div><div class="">If not, please ignore the following and accept my apologies for posting OT.</div><div class=""><br class=""></div><div class="">Typealiases in constrained extensions are - and have been, for a long time - very broken.</div><div class="">The following program (which is clearly crazy in several ways) compiles and runs using the latest version of the compiler:</div><div class=""><br class=""></div><div class="">struct S<T> {</div><div class=""> var v: This</div><div class="">}</div><div class="">extension S where T == Int {</div><div class=""> typealias This = Is</div><div class="">}</div><div class="">extension S where T == Bool {</div><div class=""> typealias Is = Fine</div><div class="">}</div><div class="">extension S where T == String {</div><div class=""> typealias Fine = T</div><div class="">}</div><div class="">let x = S<Float80>(v: "uh")</div><div class="">print(x.v) // uh</div><div class=""><br class=""></div><div class="">( SR-5440 )<br class=""></div><div class="">The current behavior is so allowing and strange that I'm having trouble seeing what the correct behavior would be if things worked as intended.</div></div></div></blockquote><div><br class=""></div><div>I’d said that “var v: This”, “typealias This = Is”, and “typealias Is = Fine” are ill-formed and the compiler should reject them. You should only be able to use types from another extension if your extra constraints imply the constraints of that extension. I *think* it’s actually a simple model, but it didn’t get implemented.</div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class="">For example should the following program still compile, and if so, should the last line also compile (if uncommented)?</div><div class=""><br class=""></div><div class=""><div class="">protocol P {</div><div class=""> associatedtype A = Int</div><div class=""> associatedtype B = Bool</div><div class=""> typealias C = Float</div><div class="">}</div><div class="">extension P where B == A {</div><div class=""> typealias C = String</div><div class="">}</div></div></div></div></blockquote><div><br class=""></div>I think this should be ill-formed, because we shouldn’t allow two typealiases with the same name to “overload” within the same type.</div><div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class=""><div class="">struct S<A, B> : P {</div><div class=""> var v: (A, B, C)</div><div class="">}</div><div class="">extension S where A == Int, B == Bool {</div><div class=""> typealias C = [String]</div><div class="">}</div><div class="">let s1 = S(v: (1, true, [""]))</div><div class="">// let s2 = S(v: ("a", "b", "c")) // Not (currently) ok.</div></div><div class=""><br class=""></div><div class="">Again, sorry for the noise if this is unrelated to the discussion.</div></div></div></blockquote><div><br class=""></div><span class="Apple-tab-span" style="white-space:pre">        </span>- Doug</div><div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class="">/Jens</div><div class=""><br class=""></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Sun, Dec 3, 2017 at 6:23 AM, Dave Abrahams via swift-evolution <span dir="ltr" class=""><<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto" class=""><span class=""><br class=""><div class="">On Nov 30, 2017, at 2:28 PM, Douglas Gregor via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>> wrote:<br class=""><br class=""></div><blockquote type="cite" class=""><div class="">Hello Swift community,<div class=""><br class=""></div><div class="">Associated type inference, which is the process by which the Swift compiler attempts to infer typealiases to satisfy associated-type requirements based on other requirements, has caused both implementation problems and user confusion for a long time. Some of you might remember a previous (failed) attempt to remove this feature from the Swift language, in <a href="https://github.com/apple/swift-evolution/blob/master/proposals/0108-remove-assoctype-inference.md" target="_blank" class="">SE-0108 “Remove associated type inference”.</a> </div><div class=""><br class=""></div><div class="">I’m not sure we can remove this feature outright (i.e., the concerns that sank that proposal are still absolutely valid), because it is so very convenient and a lot of user code likely depends on it in some form or other. So, here I’d like to describe the uses of the feature, its current (very problematic) implementation approach, and a half-baked proposal to narrow the scope of associated type inference to something that I think is more tractable. I need help with the design of this feature, because I feel like it’s going to be a delicate balance between implementability and expressiveness.</div></div></blockquote><div class=""><br class=""></div></span>Aloha, Doug!<div class=""><div class=""><div class="h5"><br class=""><blockquote type="cite" class=""><div class=""><div class=""><br class=""></div><div class=""><b class="">A Motivating Example</b></div><div class="">As a motivating example, let’s consider a “minimal” random access collection:</div><div class=""><br class=""></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><div class=""><font face="Menlo" class="">struct MyCollection<T> {</font></div></div><div class=""><div class=""><font face="Menlo" class=""> var contents: [T]</font></div></div><div class=""><div class=""><font face="Menlo" class="">}</font></div></div><div class=""><div class=""><font face="Menlo" class=""><br class=""></font></div></div><div class=""><div class=""><font face="Menlo" class="">extension MyCollection: RandomAccessCollection { </font></div></div><div class=""><div class=""><font face="Menlo" class=""> var startIndex: Int { return contents.startIndex }</font></div></div><div class=""><div class=""><font face="Menlo" class=""> var endIndex: Int { return contents.endIndex }</font></div></div><div class=""><div class=""><font face="Menlo" class=""> subscript(index: Int) -> T { return contents[index] }</font></div></div><div class=""><div class=""><font face="Menlo" class="">}</font></div></div></blockquote><div class=""><br class=""></div><div class="">This is actually pretty awesome: by providing just two properties and a subscript, we get the full breadth of the random access collection API! This is relying heavily on associated type inference (for associated type requirements) and default implementations specified on protocol extensions. Without associated type inference, we would have had to write:</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">extension MyCollection: RandomAccessCollection {</font></div><div class=""><font face="Menlo" class=""><b class=""> typealias Element = T</b></font></div><div class=""><font face="Menlo" class=""><b class=""> typealias Index = Int</b></font></div><div class=""><font face="Menlo" class=""><b class=""> typealias Indices = CountableRange<Int></b></font></div><div class=""><font face="Menlo" class=""><b class=""> typealias Iterator = IndexingIterator<MyCollection<<wbr class="">T>></b></font></div><div class=""><font face="Menlo" class=""><b class=""> typealias SubSequence = RandomAccessSlice<<wbr class="">MyCollection<T>></b></font></div><div class=""><font face="Menlo" class=""> </font></div><div class=""><font face="Menlo" class=""> var startIndex: Int { return contents.startIndex }</font></div><div class=""><font face="Menlo" class=""> var endIndex: Int { return contents.endIndex }</font></div><div class=""><font face="Menlo" class=""> subscript(index: Int) -> T { return contents[index] }</font></div><div class=""><font face="Menlo" class="">}</font></div><div class=""><font face="Menlo" class=""><br class=""></font></div></blockquote></div><div class="">where the bolded typealiases are currently inferred. It was worse back when we reviewed SE-0108, because IIRC there were a few underscored associated types (e.g., _Element) that have since been removed. Still, that’s a bit of additional work to define a “minimal” collection, and requires quite a bit more understanding: how do I know to choose IndexingIterator, and CountableRange, and RandomAccessSlice?</div><div class=""><br class=""></div><div class="">The issue would get worse with, e.g., <a href="https://github.com/apple/swift-evolution/blob/master/proposals/0174-filter-range-replaceable.md" target="_blank" class="">SE-0174 “Change filter to return an associated type”</a>, which adds an associated type Filtered that almost nobody will ever customize, and isn’t really fundamental to the way collections work. Adding Filtered to the standard library would be a source-breaking change, because users would have to write a typealias giving it its default.</div><div class=""><br class=""></div><div class=""><b class="">Associated Type Defaults</b></div><div class="">One of the ways in which we avoid having to specify typealiases is to use associated type defaults. For example, the standard library contains associated type defaults for Indices, Iterator, and SubSequence. Let’s focus on Indices:</div><div class=""><br class=""></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">protocol Collection : Sequence {</font></div><div class=""><font face="Menlo" class=""> associatedtype Indices = DefaultIndices<Self></font></div><div class=""><font face="Menlo" class=""> // ...</font></div><div class=""><font face="Menlo" class="">}</font></div><div class=""><font face="Menlo" class=""><br class=""></font></div><div class=""><div class=""><font face="Menlo" class="">protocol BidirectionalCollection : Collection {</font></div></div><div class=""><div class=""><font face="Menlo" class=""> associatedtype Indices = DefaultBidirectionalIndices<<wbr class="">Self></font></div></div><div class=""><div class=""><font face="Menlo" class=""> // ...</font></div></div><div class=""><div class=""><font face="Menlo" class="">}</font></div></div><div class=""><font face="Menlo" class=""><br class=""></font></div><div class=""><div class=""><font face="Menlo" class="">protocol RandomAccessCollection : BidirectionalCollection {</font></div></div><div class=""><div class=""><font face="Menlo" class=""> associatedtype Indices = DefaultRandomAccessIndices<<wbr class="">Self></font></div></div><div class=""><div class=""><font face="Menlo" class=""> // ...</font></div></div><div class=""><div class=""><font face="Menlo" class="">}</font></div></div></blockquote><div class=""><br class=""></div><div class="">The basic idea here is that different protocols in the hierarchy provide different defaults, and you presumably want the default from the most specific protocol. If I define a type and make it conform to BidirectionalCollection, I’d expect to get DefaultBidirectionalIndices<<wbr class="">Self> for Indices. If a define a type and make it conform to RandomAccessIterator, I’d expect to get DefaultRandomAccessIndices<<wbr class="">Self>.</div><div class=""><br class=""></div><div class="">(Aside: DefaultRandomAccessIndices and DefaultBidirectionalIndices got collapsed into DefaultIndices now that we have <a href="https://github.com/apple/swift/pull/12913" target="_blank" class="">conditional conformances for the standard library</a>, but the issues I’m describing remain).</div><div class=""><br class=""></div><div class="">Associated type defaults seem like a reasonable feature that fits well enough into the design. However, it’s not the only thing in place with our MyCollection example, for which Indices was inferred to CountableRange. How’s that happen?</div><div class=""><br class=""></div><div class=""><b class="">Associated Type Inference</b></div><div class="">Associated type inference attempts to look at the requirements of a protocol, and then looks into the conforming type for declarations that might satisfy those requirements, and infers associated types from the types of those declarations. Let’s look at some examples. RandomAccessCollection has some requirements that mention the Index and Element types:</div><div class=""><br class=""></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">protocol RandomAccessCollection : BidirectionalCollection {</font></div><div class=""><font face="Menlo" class=""> associatedtype Element</font></div><div class=""><font face="Menlo" class=""> associatedtype Index</font></div><div class=""><font face="Menlo" class=""><br class=""></font></div><div class=""><font face="Menlo" class=""> var startIndex: Index { get }</font></div><div class=""><font face="Menlo" class=""> var endIndex: Index { get }</font></div><div class=""><font face="Menlo" class=""> subscript (i: Index) -> Element { get }</font></div><div class=""><font face="Menlo" class="">}</font></div></blockquote><div class=""><br class=""></div><div class="">Associated type inference wil try to satisfy those requirements for MyCollection, and will find these declarations:</div><div class=""><br class=""></div><div class=""><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">extension MyCollection: RandomAccessCollection { </font></div><div class=""><font face="Menlo" class=""> var startIndex: Int { return contents.startIndex }</font></div><div class=""><font face="Menlo" class=""> var endIndex: Int { return contents.endIndex }</font></div><div class=""><font face="Menlo" class=""> subscript(index: Int) -> T { return contents[index] }</font></div><div class=""><font face="Menlo" class="">}</font></div><div class=""><br class=""></div></blockquote></div><div class="">and match them up. From startIndex, we infer Index := Int. From endIndex, we infer Index := Int. From subscript, we infer Index := Int and Element := T. Those results are all consistent, so we’ve properly inferred Index and Element. Yay.</div><div class=""><br class=""></div><div class="">Associated type inference often has to deal with ambiguities. For example, there is an extension of Collection that provides a range subscript operator:</div><div class=""><br class=""></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">extension Collection {</font></div><div class=""><font face="Menlo" class=""> subscript (bounds: Range<Index>) -> Slice<Self> { … }</font></div><div class=""><font face="Menlo" class="">}</font></div></blockquote><div class=""><br class=""></div><div class="">When we look at that and match it to the subscript requirement in RandomAccessCollection (remembering that argument labels aren’t significant for subscripts by default!), we infer Index := Range<Index> (admittedly weird) and Element := Slice<Self> (could be legitimate). We have to discard this candidate because the deduction from startIndex/endIndex (Index := Int) collides with this deduction (Index := Range<Index>).</div><div class=""><br class=""></div><div class="">In our initial example, we saw that Indices was inferred to CountableRange<Int>. Let’s look at another slice of the RandomAccessCollection protocol that’s relevant to this associated type:</div><div class=""><br class=""></div><div class=""><blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px" class=""><div class=""><font face="Menlo" class="">protocol RandomAccessCollection : BidirectionalCollection {</font></div><div class=""><font face="Menlo" class=""> associatedtype Index</font></div><div class=""><font face="Menlo" class=""> associatedtype Indices: RandomAccessCollection where Indices.Element == Index</font></div><div class=""><br class=""></div><div class=""><font face="Menlo" class=""> var indices: Indices { get }</font></div><div class=""><span style="font-family:Menlo" class="">}</span></div><div class=""><font face="Menlo" class=""><br class=""></font></div></blockquote></div><div class="">We will match that requirement for an “indices” property against a member of a constrained protocol extension of RandomAccessCollection:</div><div class=""><br class=""></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><div class=""><font face="Menlo" class="">extension RandomAccessCollection where Index : Strideable, Index.Stride == IndexDistance, Indices == CountableRange<Index> {</font></div></div><div class=""><div class=""><font face="Menlo" class=""> public var indices: CountableRange<Index> {</font></div></div><div class=""><div class=""><font face="Menlo" class=""> return startIndex..<endIndex</font></div></div><div class=""><div class=""><font face="Menlo" class=""> }</font></div></div><div class=""><font face="Menlo" class="">}</font></div></blockquote><div class=""><br class=""></div><div class="">Associated type inference can determine here that Indices := CountableRange<Index>, but only when Index: Strideable and Index.Stride == IndexDistance. In other words, there are a whole bunch of other constraints to verify before we can accept this inference for Indices.</div></div></blockquote><div class=""><br class=""></div></div></div>So, what’s the problem? ;-)<div class=""><span class=""><br class=""><blockquote type="cite" class=""><div class=""><div class=""><b class="">What’s a Good Solution Look Like?</b></div><div class="">Our current system for associated type inference and associated type defaults is buggy and complicated. </div></div></blockquote><div class=""><br class=""></div></span>Well, <i class="">that’s</i> the problem, then. Don’t worry, I won’t suggest that you simply fix the implementation, because even if there weren’t bugs and the system were predictable I’d still think we could improve the situation for users by making associated type default declarations more explicit.</div><div class=""><span class=""><br class=""><blockquote type="cite" class=""><div class=""><div class="">The compiler gets it right often enough that people depend on it, but I don’t think anyone can reasonably be expected to puzzle out what’s going to happen, and this area is rife with bugs. If we were to design a new solution from scratch, what properties should it have?</div><div class=""><br class=""></div><div class=""><ul class="m_-5718454513244834095MailOutline"><li class="">It should allow the author of a protocol to provide reasonable defaults, so the user doesn’t have to write them</li><li class="">It shouldn’t require users to write typealiases for “obvious” cases, even when they aren’t due to defaults</li><li class="">It shouldn’t infer an inconsistent set of typealiases</li><li class="">It should be something that a competent Swift programmer could reason about when it will succeed, when and why it will fail, and what the resulting inferred typealiases would be</li><li class="">It should admit a reasonable implementation in the compiler that is performant and robust</li></ul></div></div></blockquote></span>• It should cover all of the existing use cases.</div><div class=""><span style="background-color:rgba(255,255,255,0)" class="">• It should not break code at this point.</span></div><div class="">• We should have a migration strategy for existing code that avoids traps like silent semantic changes.</div><div class=""><br class=""></div><div class="">My bullet is important to me; I don’t think existing use cases are (inherently) so complex that we can sacrifice almost any of them and still end up with a sufficiently useful system. At the very least, existing use cases provide the only guidance we really have as to what the feature should do.</div><div class=""><br class=""></div><div class="">I think we need to acknowledge that my second bullet is unattainable, at least if we want to improve type checking performance. Not breaking any code means that given any existing code, the compiler would have to explore the same solution space it currently does, and come up with the same answers. Improving performance would require new declarations to use totally optional explicit syntax to prevent some explorations, and that’s an untenable user experience.</div><div class=""><br class=""></div><div class="">Which brings me to my third bullet: unless we are willing to break the code of protocol <i class="">users</i> (as opposed to vendors) we need to ensure that vendors can confidently convert code to use the new system without changing semantics.</div><div class=""> </div><div class=""><span class=""><blockquote type="cite" class=""><div class=""><div class=""><br class=""></div><div class=""><b class="">A Rough Proposal</b></div><div class="">I’ve been thinking about this for a bit, and I think there are three ways in which we should be able to infer an associated type witness:</div><div class=""><br class=""></div><div class=""><ol class="m_-5718454513244834095MailOutline"><li class="">Associated type defaults, which are specified with the associated type itself, e.g.,<br class=""><br class=""><font face="Menlo" class=""> associatedtype Indices = DefaultIndices<Self><br class=""></font><br class="">These are easy to reason about for both the programmer and the compiler.</li><li class="">Typealiases in (possibly constrained) protocol extensions, e.g.,<br class=""><br class=""><font face="Menlo" class=""> extension RandomAccessCollection where Index : Strideable, Index.Stride == IndexDistance {</font><br class=""><font face="Menlo" class=""> typealias RandomAccessCollection.Indices = CountableRange<Index></font><br class=""><font face="Menlo" class=""> }</font><br class=""><br class="">I’m intentionally using some odd ‘.’ syntax here to indicate that this typealias is intended only to be found when trying to satisfy an associated type requirement, and is not a general typealias that could be found by normal name lookup. Let’s set the syntax bike shed aside for the moment. The primary advantage of this approach (vs. inferring Indices from “var Indices: CountableRange<Index>” in a constrained protocol extension) is that there’s a real typealias declaration that compiler and programmer alike can look at and reason about based just on the name “Indices”. <br class=""><br class="">Note that this mechanism technically obviates the need for (1), in the same sense that <a href="https://github.com/apple/swift/blob/master/docs/GenericsManifesto.md#default-implementations-in-protocols-" target="_blank" class="">default implementations in protocols</a> are merely syntactic sugar.</li><li class="">Declarations within the nominal type declaration or extension that declares conformance to the protocol in question. This is generally the same approach as described in “associated type inference” above, where we match requirements of the protocol against declarations that could satisfy those requirements and infer associated types from there. However, I want to turn it around: instead of starting with the requirements of the protocol any looking basically anywhere in the type or any protocol to which it conforms (for implementations in protocol extensions), start with the declarations that the user explicitly wrote at the point of the conformance and look for requirements they might satisfy. For example, consider our initial example:<br class=""><br class=""><div class=""><font face="Menlo" class=""> extension MyCollection: RandomAccessCollection { </font></div><div class=""><font face="Menlo" class=""> var startIndex: Int { return contents.startIndex }</font></div><div class=""><font face="Menlo" class=""> var endIndex: Int { return contents.endIndex }</font></div><div class=""><font face="Menlo" class=""> subscript(index: Int) -> T { return contents[index] }</font></div><div class=""><font face="Menlo" class=""> }<br class=""><br class=""></font></div>Since startIndex, endIndex, and subscript(_:) are declared in the same extension that declares conformance to RandomAccessIterator, we should look for requirements with the same name as these properties and subscript within RandomAccessCollection (or any protocol it inherits) and infer Index := Int and Element := T by matching the type signatures. This is still the most magical inference rule, because there is no declaration named “Index” or “Element” to look at. However, it is much narrower in scope than the current implementation, because it’s only going to reason from the (probably small) set of declarations that the user wrote alongside the conformance, so it’s more likely to be intentional. Note that this is again nudging programmers toward the style of programming where one puts one protocol conformance per extension, which is admittedly my personal preference.</li></ol></div><div class=""><div class=""><br class=""></div></div><div class=""><b class="">Thoughts?</b></div></div></blockquote><div class=""><br class=""></div></span>The thing that strikes me most about these is that the first two are explicit declarations of intent: “In the absences of an explicit declaration, deduce this associated type as follows,” while the third is still extremely indirect. While it hints to the compiler about which conformances’ associated type requirements we are trying to satisfy, it never comes out and says straight out what the associated type should be, even though it needs to be mentioned. As a generic programmer, I don’t value the concision gained over the clarity lost, and I’d like to see the solutions to these problems follow the explicit-declaration-of-intent pattern. However, the code in #3 is not written by the protocol vendor, and for me it is (at least currently) a stretch to think of breaking the code of protocol users, so I grudgingly accept it. </div><div class=""><br class=""></div><div class="">If we were <i class="">really</i> starting from scratch I might suggest requiring that conformances use the associated type name rather than some concrete type, e.g. </div><div class=""><br class=""></div><div class=""><div class=""><font style="background-color:rgba(255,255,255,0)" class="">extension MyCollection: RandomAccessCollection { </font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""> typealias RandomAccessCollection.Index = Int</font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""> var startIndex: Index { return contents.startIndex }</font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""> var endIndex: Index { return contents.endIndex }</font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""> subscript(index: Index) -> Element { return contents[index] }</font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""> }</font></div></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""><br class=""></font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class="">But I suspect we’re well past the point in the language’s evolution where that sort of change is possible.</font></div><div class=""><font style="background-color:rgba(255,255,255,0)" class=""><br class=""></font></div><div class="">As for migration of protocol user code, I think we’d need to run both the new and the old slow inference in the migrator and flag any differences. I don’t know what to do about protocol vendors’ code though.</div><span class=""><div class=""><br class=""><blockquote type="cite" class=""><div class=""><div class="">I think this approach is more predictable and more implementable than the current model. I’m curious whether the above makes sense to someone other than me, and whether it covers existing use cases well enough. Thoughts?</div></div></blockquote><br class=""></div></span><div class="">Well, covering the use cases is definitely still a concern for me. I don’t think we’ll know for sure until we try it, but have you thought about how to migrate each piece of code in the standard library? Does it cover those cases?</div><div class=""><br class=""></div><div class="">-Dave</div><div class=""><br class=""></div><div class=""><span style="background-color:rgba(255,255,255,0)" class=""><br class=""><br class=""></span><div class=""><span style="background-color:rgba(255,255,255,0)" class="">Sent from my iPad</span></div></div><div class=""><br class=""></div></div></div><br class="">______________________________<wbr class="">_________________<br class="">
swift-evolution mailing list<br class="">
<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class="">
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank" class="">https://lists.swift.org/<wbr class="">mailman/listinfo/swift-<wbr class="">evolution</a><br class="">
<br class=""></blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></body></html>