i’ve got an actor with a non-Sendable stored property allocations.
public final
actor ConnectionPool
{
/// The connections stored in this pool.
private
var allocations:Allocations
...
}
the actor has a deinit, but the compiler doesn’t like when i access self.allocations in the deinit.
deinit
{
self.allocations.destroy()
// cannot access property 'allocations' with a non-sendable type
// 'Mongo.ConnectionPool.Allocations' from non-isolated deinit;
// this is an error in Swift 6
}
SE-0371 was returned for revision. are there any sensible ways to resolve this problem?
1 Like