We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ac65276 commit a71fdd5Copy full SHA for a71fdd5
Sources/RandomKit/Types/RandomGenerator/ThreadLocal.swift
@@ -66,8 +66,8 @@ private var _keys = [ObjectIdentifier: pthread_key_t]()
66
67
private let _keysLock = _RWLock()
68
69
-private func _key<T>(for _: T.Type) -> pthread_key_t {
70
- let id = ObjectIdentifier(T.self)
+private func _key(for type: Any.Type) -> pthread_key_t {
+ let id = ObjectIdentifier(type)
71
if let key = _keysLock.withReadLock({ _keys[id] }) {
72
return key
73
} else {
0 commit comments