Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Conversion to Swift 5 is available [closed]

I'm getting this warning in Xcode 10.2.

Conversion to swift 5 is available

enter image description here

When i click this error it's opening this window

enter image description here

When we click NEXT what will happen...

like image 972
Naresh Avatar asked Apr 22 '19 06:04

Naresh


People also ask

How to convert to Swift 5?

We can resolve this by navigating to our project settings and select the tab “Build Settings”. Search for “Swift Language Version” and select Swift 5 from the dropdown menu: You can do this for every target you want to convert to Swift 5 (I recommend to update to Swift 5 for all your targets).

How do I update my swift 3 to swift 5?

You need to redownload Xcode 10.1 from this page, convert your code to Swift 4, then redownload Xcode 10.2 and convert to Swift 5. The only other option I can think of is changing your Swift Version in your apps bundle and then seeing if it lets you convert but I don't think it will. Show activity on this post.

How do I ignore a warning in Swift?

If you want to disable all warnings, you can pass the -suppress-warnings flag (or turn on "Suppress Warnings" under "Swift Compiler - Warning Policies" in Xcode build settings).


1 Answers

the current version of swift is swift5 which is only supported in Xcode 10.2 and you are using another version like swift4 or swift4.2 in xcode 10.2. This warning means that a new version of Swift is available if you click this warning you will receive a pop up and will ask for permission to convert your code to latest version of swift (which is now swift5). if you click yes to the pop up Xcode automatically convert your code to newest version of swift(which is swift5 in your case)

like image 101
Goal Tech Avatar answered Sep 20 '22 18:09

Goal Tech