Avatar
ありがとうございますmm Acceptedステータスで実装済のものがどのバージョンで使えるようになるのかがわからず... ↓は6.0になっているのですが、これは今のままでも問題ないということなんですかね? https://github.com/apple/swift-evolution/blob/main/proposals/0421-generalize-async-sequence.md extension AsyncIteratorProtocol { /// Default implementation of `next(isolation:)` in terms of `next()`, which is /// required to maintain backward compatibility with existing async iterators. @available(SwiftStdlib 6.0, *) @available(*, deprecated, message: "Provide an implementation of 'next(isolation:)'") public mutating func next(isolation actor: isolated (any Actor)?) async throws(Failure) -> Element? { nonisolated(unsafe) var unsafeIterator = self do { let element = try await unsafeIterator.next() self = unsafeIterator return element } catch { throw error as! Failure } } } (edited)
This maintains proposals for changes and user-visible enhancements to the Swift Programming Language. - apple/swift-evolution