Xcode 14.0, 14.1 release100% crash with swift + OC file, ** only init no use

Xcode 14.0 and 14.0.1 swift project crash(release, OC file, ** obj only init no use) (Xcode 13.x normal)。

Crash Info: Thread 1: EXC_BAD_ACCESS (code=1, address=0x9a0080020).symbol stub for: static Swift.CommandLine.unsafeArgv.getter : Swift.UnsafeMutablePointer<Swift.Optional<Swift.UnsafeMutablePointer<Swift.Int8>>>

no use: var errorItem:TestError? = TestError() use: var errorItem:TestError?

In your second screen shot, look at the backtrace on the left. Xcode has selected the topmost frame for which it has source code, but that’s frame 23, which is far removed from the origin of the crash in frame 0. All we can see about frame 0 is the routine name, objc_retain, which suggests you have a memory management problem. However, we can’t see anything about how you got there.

If you detach from the process when its in this state (by choosing Debug > Detach), the process will crash and the system will generate a crash report for it. Please post that crash report. See Posting a Crash Report for advice on how to do that.

Share and Enjoy

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

Xcode 14.0, 14.1 release100% crash with swift + OC file, ** only init no use
 
 
Q