Replies: 1 comment
-
Hi @rhr-gc, this is definitely an interesting idea, but in the long run we plan on deprecating |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I see that
LockIsolated
uses anNSRecursiveLock
as the synchronization mechanism. I also notice that to get a value stored byLockIsolated
the pattern is to use thevalue
computed property. This calls into thelock()
function ofNSRecursiveLock
.NSLocking
provides a methodlock(before:)
that allows client code to supply a timeout parameter. I think this would be a useful addition toLockIsolated
. In my specific case, there is a low-priority piece of data that would be nice to have when sending along a network request, but not necessary - and ultimately not worth blocking the network request. Being able to request aLockIsolated
value with a timeout would be valuable.Beta Was this translation helpful? Give feedback.
All reactions