Swift Journey Log

Using Preprocessor Macros: func println(object: Any) { #if DEBUG Swift.println(object) #endif } And just set “DEBUG” as a custom flag for the Swift compiler (Build Settings –> Swift Compiler –> Custom Flags) Debug: -DDEBUG Release: -DRELEASE Add a bridging header to import Objective-C code: Add empty header file to project (e.g., Bridging.h). Add all your #import statements in that file. In Project Build Settings, go to Swift Compiler - Code Generation and add path to previously created Bridging.