map
は [Element]
を返すとか一貫性なくないですか?そして、 map
についても Mapped
を作ろうとしたら、 higher-kinded type がないといけないという・・・。 https://github.com/apple/swift-evolution/blob/master/proposals/0174-filter-range-replaceable.mdIt could be worthwhile to make a similar change to map, but this is beyond the capabilities of the current generics system because map does not preserve the element type