I ran into an irritating problem with a project using CocoaPods. The codebase is written to a major part in Obj-C, but I’ve started initiating new code in Swift. I got these irritating Swift Compiler warnings that I had to add the frameworks for SystemConfiguration and MobileCoreServices . I was prompted to add them to the <ModuleName>-Prefix.pch – file but they already where.
I silenced the by adding the headers to the bridge-files:
1 2 3 4 5 6 |
// Added to // <Module>-Bridging-Header.h and // <TestModule>-Bridging-Header, respectivly #import <SystemConfiguration/SystemConfiguration.h> #import <MobileCoreServices/MobileCoreServices.h> |
This occurred in a project, which started as an Obj-C-project but later on added support for Swift files.