`associatedtype` and `typealias-assignment`

An associated type declaration is defined as:

protocol-associated-type-declaration → attributes opt access-level-modifier opt associatedtype typealias-name type-inheritance-clause opt typealias-assignment opt generic-where-clause opt

I've not had any luck in finding a resource on what effect the typealias-assignment element in this syntax has. Neither the swift.org docs or Apple's The Swift Programming Language ebook appear to mention this element of the syntax in their description of generics or associated types in particular.

Can anyone shed some light?

Further on the topic, I was curious if there is any interest or initiative in the direction of allowing the generic type parameter specification to be made optional in the context of type parameters that have a default type specified or that could be inferred (eg. from this token in the associatedtype syntax)?

protocol Box {
    associatedtype T = Void
    var value: T? { get }
struct SimpleBox<T>: Box {
    var value: T?


func f() -> SimpleBox<_> {}

Would be interesting if something like this was possible.

typealias-assignment= type

See: Declarations — The Swift Programming Language (Swift 5.7)

In a protocol, it allows you to specify a default associated type.

Thanks for the link; this is also where I found the declaration definition in the OP; though there is scant information on what the effect of such a default might be in the context of an associated type in a protocol.