Misusing a Mutex

This is a successor to:

https://developer.apple.com/forums/thread/814231

I went into a slightly different direction. I generated more AI slop that use NSLock. Then I had the NSLock usage changed to Mutex usage. Now it crashes with:

Task 13: EXC_BREAKPOINT (code=1, subcode=0x18d29326c)

On one of the mutex closures. With an extended description:

warning: TypeSystemSwiftTypeRef::operator(): had to engage SwiftASTContext fallback for type $s7Combine10PublishersO21LineBreakingPublisherE11SplitAtZeroV12Subscription33_D18F5AAE73662968F407B0A79FBD1F8DLLCy_x_qd__GD

I put the class, a Subscription nested in its corresponding Publisher operator, in the given file

You mean that the compiler crashes?

If so, that’s probably something best addressed over in Swift Forums > Using Swift.

And speaking generally, to improve your chances of getting traction:

  • Be clear about what version of the compiler you’re testing with.
  • Isolate the code into a small test project that reproduces the issue.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Misusing a Mutex
 
 
Q