Nerdy Bunz
Nerdy Bunz

Reputation: 7437

Xcode giving version compatibility warning for unknown reason

I think the two screen-shots make this question self-explanatory.

Am I taking crazy pills here? Please help.

enter image description here

enter image description here

Upvotes: 1

Views: 64

Answers (2)

Kamani Jasmin
Kamani Jasmin

Reputation: 711

You got this error because your version is lowest. so, you can add this code on top of your function if you want to run your app in lowest version.

@available(iOS 10.0, *)
func youFunctionName() {

}

if you want to run your app in letest version you can do it. select your project -> General -> Targets -> Deployment Info -> Deployment Targets -> 10.0

Upvotes: 1

clemens
clemens

Reputation: 17721

This is the Deployment Target of your project. Check the value for the Target. Just delete the value in the target setting than the target will inherit the value from the project.

Upvotes: 1

Related Questions