> On Dec 19, 2015, at 11:14 PM, Dave Abrahams via swift-evolution 
> <[email protected]> wrote:
> 
>> On Dec 19, 2015, at 5:09 PM, Brent Royal-Gordon via swift-evolution 
>> <[email protected]> wrote:
>> 
>> I don't think `required` captures the intended meaning *at all*. You're not 
>> required to declare the type of a "required typealias"—it's often, perhaps 
>> even usually, inferred.
> 
> No, but it is required to exist and can't always be inferred.  It puts a 
> constraint on the type that is declared to conform.  This is a requirement in 
> exactly the same sense that other protocol requirements are requirements.  
> Notably operator requirements may be satisfied "implicitly" by declarations 
> that already exist, but they are still requirements.

I think reusing "required" here (where "typealias" has already been reused) 
could make the concept of associated types more opaque to new users.

The use of "typealias" as a kind of "typedef" immediately made sense to me. 
When I first stumbled upon "typealias" in a protocol, it took me some time to 
fully grok its use and its connection to its "typedef" counterpart.

Stephen
_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to