Swift: Extension on [<SomeType<T>?] to produce [<T>?] possible?
问题 In Swift, I have a custom struct with this basic premise: A wrapper struct that can contain any type that conforms to BinaryInteger such as Int, UInt8, Int16, etc. protocol SomeTypeProtocol { associatedtype NumberType var value: NumberType { get set } } struct SomeType<T: BinaryInteger>: SomeTypeProtocol { typealias NumberType = T var value: NumberType } And an extension on Collection: extension Collection where Element: SomeTypeProtocol { var values: [Element.NumberType] { return self.map {