mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-27 04:14:21 +00:00
StrictConcurrency: ValueConcurrentObserver is Sendable
Required for DatabaseCancellable conformance
This commit is contained in:
1 parent
5465d056ab
commit
87b9db65d1
1 file changed
+7
-2
@@ -18,7 +18,12 @@ import Foundation
|
|||||||
/// reducing stage.
|
/// reducing stage.
|
||||||
///
|
///
|
||||||
/// **Notify** is calling user callbacks, in case of database change or error.
|
/// **Notify** is calling user callbacks, in case of database change or error.
|
||||||
final class ValueConcurrentObserver<Reducer: ValueReducer, Scheduler: ValueObservationScheduler> {
|
final class ValueConcurrentObserver<
|
||||||
|
Reducer: ValueReducer,
|
||||||
|
Scheduler: ValueObservationScheduler>: @unchecked Sendable
|
||||||
|
{
|
||||||
|
// @unchecked Sendable: see Mutable State below.
|
||||||
|
|
||||||
// MARK: - Configuration
|
// MARK: - Configuration
|
||||||
//
|
//
|
||||||
// Configuration is not mutable.
|
// Configuration is not mutable.
|
||||||
@@ -72,7 +77,7 @@ final class ValueConcurrentObserver<Reducer: ValueReducer, Scheduler: ValueObser
|
|||||||
// be notified. See error catching clauses.
|
// be notified. See error catching clauses.
|
||||||
|
|
||||||
/// Ability to access the database
|
/// Ability to access the database
|
||||||
private struct DatabaseAccess {
|
private struct DatabaseAccess: Sendable {
|
||||||
/// The observed DatabasePool.
|
/// The observed DatabasePool.
|
||||||
let dbPool: DatabasePool
|
let dbPool: DatabasePool
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user