Avatar
protocol MySequence { associatedtype Iterator: MyIterator func makeIterator() -> Iterator } protocol MyIterator: MySequence { associatedtype Element func next() -> Element? } extension MyIterator { func makeIterator() -> Self { return self } } MyPlayground.playground:3:20: Type may not reference itself as a requirement 実装都合な気もしてきた