Undefined symbols for architecture x86_64

I'm getting undefined symbol for my own Swift class used from ObjC when linking in x86_64. I pinpointed the issue to using CheckedContinuation inside the class, because if I remove the use of it, it links. What could be the issue?

BTW, this class is marked @available(macOS 10.15, *) and the target is set to 10.12.

Interesting. If I change CheckedContinuation to UnsafeContinuation and also all withCheckedThrowingContinuation to withUnsafeThrowingContinuation, it now links.

Please post your hardware and OS-level setup as well.

MacBook Pro M1. But also happens on a build machine with Intel. macOS Ventura 13.5.

What Xcode are you building with?

Because I thought I’d give this a try myself and ran into an immediate roadblock: With Xcode 14.3, the minimum deployment target is 10.13.

Share and Enjoy

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

Undefined symbols for architecture x86_64
 
 
Q