MeetingNotes icon indicating copy to clipboard operation
MeetingNotes copied to clipboard

update example code to make ReferenceFileDocument sendable

Open heckj opened this issue 1 year ago • 0 comments

latest Xcode (16) and associated SDKs have marked ReferenceFileDocument as Sendable. I inquired in the developer forums about this, and the DTS engineer kindly explained that it has to be Sendable - which means adding some structure in there - because the various methods are called from a number of different isolation domains.

The gist is that the class holds ~3-4 properties that are all possibly mutating, and all of those need to be locked down to Sendable, so wrapped within an OSUnfairAllocatedLock (as per updated ReferenceFileDocument code example).

heckj avatar Oct 02 '24 21:10 heckj