AsyncValueObservation is Sendable

This commit is contained in:
Gwendal Roué committed 2024-07-28 13:59:38 +02:00
1 parent 48ad10aea8
commit ce63cdfa60
2 files changed
+4 -3

No files matched your search

+3 -2
View File
@@ -81,7 +81,7 @@ struct ValueObservationEvents: Refinable {
var didCancel: (@Sendable () -> Void)?
}
typealias ValueObservationStart<T> = (
typealias ValueObservationStart<T> = @Sendable (
_ onError: @escaping @Sendable (Error) -> Void,
_ onChange: @escaping @Sendable (T) -> Void)
-> AnyDatabaseCancellable
@@ -339,7 +339,8 @@ extension ValueObservation {
/// You build an `AsyncValueObservation` from ``ValueObservation`` or
/// ``SharedValueObservation``.
@available(iOS 13, macOS 10.15, tvOS 13, *)
public struct AsyncValueObservation<Element>: AsyncSequence {
public struct AsyncValueObservation<Element>: AsyncSequence, @unchecked Sendable {
// @unchecked Sendable because of `BufferingPolicy`.
public typealias BufferingPolicy = AsyncThrowingStream<Element, Error>.Continuation.BufferingPolicy
public typealias AsyncIterator = Iterator
+1 -1
View File
@@ -113,7 +113,7 @@
- [X] association
- [X] associationaggregate
- [X] associationtomany
- [ ] asyncvalueobservation
- [X] asyncvalueobservation
- [ ] asyncvalueobservation/iterator
- [X] asyncvalueobservationscheduler
- [ ] belongstoassociation