[swift-evolution] [Review] SE-0089: Replace protocol<P1, P2> syntax with Any<P1, P2>

Vladimir.S svabox at gmail.com
Wed May 25 13:13:33 CDT 2016


On 25.05.2016 20:28, Dmitri Gribenko via swift-evolution wrote:
> var x3: Any<Hashable, Comparable> // 'x3' is any of the following
> types.  Either a Hashable, or a Comparable.

Support that Any<Some, Another> could be confusing and could be read as 
"any Some or any Another". Although as I understand there is no support for 
this, I probably think this is more clear:

var x3: Any<Hashable & Comparable>

and reads like a poem ;-) "any that is hashable AND comparable"


More information about the swift-evolution mailing list