Skip to content

Commit 7c0a002

Browse files
author
Guilherme Souza
committed
Move Weak type to Helpers module
1 parent 5510090 commit 7c0a002

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Sources/Realtime/V2/Weak.swift renamed to Sources/Helpers/Weak.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@
77

88
import Foundation
99

10-
final class Weak<T: AnyObject & Sendable>: @unchecked Sendable {
10+
package final class Weak<T: AnyObject & Sendable>: @unchecked Sendable {
1111
let lock = NSRecursiveLock()
1212
private weak var _value: T?
1313

14-
var value: T? {
14+
package var value: T? {
1515
get { lock.withLock { _value } }
1616
set { lock.withLock { _value = newValue } }
1717
}
1818

19-
init(_ value: T?) {
19+
package init(_ value: T?) {
2020
_value = value
2121
}
2222
}

0 commit comments

Comments
 (0)