Objective-C initializers used by Swift (or not)

41 Views Asked by At

In an app that was originally created in Objective-C but now with a lot of Swift code, initializing a CGRect, for example, using CGRectMake compiles just fine on a developer's Mac using Xcode, but produces an error 'CGRectMake' has been explicitly marked unavailable here on the build server.

If I Command-Click on the function, I'm directed to the Objective_C header, where, given that message, I should see something like NS_SWIFT_UNAVAILABLE, but I don't. What would cause this different behavior on dev computers and the build server? More specifically, what can we do on the dev computer to generate the same errors the build server is generating?

We're using Xcode 14 with Swift 5.

0

There are 0 best solutions below