When i opened my project into Xcode 8 then I got the following error
Use Legacy 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
referring to a similar post on StackOverflow , Use Legacy Swift Language Version YES/NO . But it's not working for me either by doing YES or No value ?
Please help.
I have checked Use Legacy Swift Language Version to options YES/NO please check attached screenshot
As reference to this, This is what I've concluded (for Xcode 8) :
If your code is in swift version < 2.3 then :
i) convert your code to swift 2.3 and Set 'Use Legacy Swift Language Version = YES'
OR
ii) convert your code to latest swift version (might be 3.0) and Set 'Use Legacy Swift Language Version = NO'
In my case, I've used external library which was in swift 2.2 causing errors in Xcode 8.0, so I replace the same library with swift version 2.3 and used above solution 2.i). Now everything is fine.
Hope this help someone who are seeking the solution to this problem.
try converting swift code to swift3 or swift 2.3. edit -> convert -> to current swift-> select swift 3 or swift 2.3. This will works.
If you're not using pods just add this to your Info.plist - I'm on 2.3
as the option wasn't listed in build settings.
Add this to your pod-file:
Run pod-install again. Clean your project with
cdm + alt + shift + k
. Clean again usingcmd + shift + k
. Restart Xcode. Build. Now it should work.If you're not using cocoapods, you should be able to fix this issue by setting the Compiler Version attribute
Use Legacy Swift Language Version
from unspecified to Yes or No.Build settings of the project or library ->
I am using Xcode 8.3.3 After surfing too much and working around i found this solution, and this worked for me.