[swift-evolution] Question about heterogeneous collections
Jason Sadler
jason.sadler at gmail.com
Fri Apr 1 13:38:24 CDT 2016
I should double check before I post. That Stack Overflow question has the same answer Dave posted earlier in this thread, which is more correct - it just has fewer votes, and isn’t marked as the accepted answer. Sorry!
> On Apr 1, 2016, at 2:32 PM, Jason Sadler <jason.sadler at gmail.com> wrote:
>
> Thanks everyone for your answers - this has helped p a lot. However because I’m not a language design pro, I’m a little unclear still on what the difference is between `Element == MyProtocol` and `Element: MyProtocol`. Obviously the latter is “Element conforms to MyProtocol” but I don’t know how to make an English sentence out of the former.
>
> I re-read some of the Generics chapter in the Swift book this morning but I wasn’t able to solidify my model of these two concepts. Based on the lack of information when searching on Stack Overflow (the most helpful thing I’ve found was this, which suggests putting things in a box: http://stackoverflow.com/questions/33112559/protocol-doesnt-conform-to-itself/33524927#33524927) and asking on swift-users, could I suggest that this could use some more explicit documentation somewhere?
>
> Thanks again,
> Jason
More information about the swift-evolution
mailing list