Taracque / ionic-plugin-callkit

Ionic/Cordova plugin for CallKit
36 stars 20 forks source link

Fix Swift 3 compilation #11

Open phyr0s opened 7 years ago

Taracque commented 7 years ago

private is still valid in Swift 3. You can read the difference between private and fileprivate here: https://cocoacasts.com/what-is-the-difference-between-private-and-fileprivate-in-swift-3/ Why you think, that should be changed? I think the reason why your XCode want to update swift code is that Swift Language Version is not defined in the project.

phyr0s commented 7 years ago

Well Xcode Says that is not updated to Swift 3.

You can create one blank ionic app , add the plugin and cordova build ios. You will see one log saying that is not updated to swift 3

Taracque commented 7 years ago

Please try to do the same thing with your modifications. For me the same thing happens. The ionic build ios displays the following message: “Swift Language Version” (SWIFT_VERSION) is required to be configured correctly for targets which use Swift. Use the [Edit > Convert > To Current Swift Syntax…] menu to choose a Swift version or use the Build Settings editor to configure the build setting directly. So somehow the SWIFT_VERSION flag needs to set up, to fix this.

nunovieira commented 7 years ago

I've added cordova-plugin-add-swift-support to fix this.