Will Swift 2.0 be compatible with OS X 10.9 or lower?

I am currently working with a beta version of Swift 2.0, but have read some documentation that talks about the availability of OS X 10.10 or later - in simple NS class documents (which might just be wary of Apple).

Is compatibility planned for older versions?

+4
source share
1 answer

The fastest supported Swift deployment target is OS X 10.9 and iOS 7. This does not change in Swift 2.

Some APIs, however, are only available in later versions of these operating systems. I suspect this is what you mean:

documentation that states OS X 10.10 or later is available in simple NS class documents

( . , , , "Swift ".)

Swift 2 API #available. Xcode:

if #available(iOS 8.0, OSX 10.10, *) {
    // Use Handoff APIs when available.
    let activity = NSUserActivity(activityType:"com.example.ShoppingList.view")
    activity.becomeCurrent()
} else {
    // Fall back when Handoff APIs not available.
} 
+3

Source: https://habr.com/ru/post/1606160/


All Articles