mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This does several different things to improve how platforms are described in availability diagnostics: • Mentions the platform in diagnostics for platform-specific @available(unavailable) attributes. • Replaces “OS X” with “macOS”. • Replaces “fooOS application extension” with “application extensions for fooOS”. • Replaces “on fooOS” with “in fooOS”. Fixes <rdar://problem/49963341>.
15 lines
862 B
Swift
15 lines
862 B
Swift
// RUN: %swift -typecheck -target i386-apple-watchos2.0 -verify -sdk %sdk %s
|
|
// REQUIRES: CPU=i386, OS=watchos
|
|
// REQUIRES: objc_interop
|
|
|
|
import Foundation
|
|
import Dispatch
|
|
|
|
// These are deprecated on all versions of watchOS.
|
|
_ = DispatchQueue.GlobalQueuePriority.high // expected-warning {{'high' is deprecated in watchOS: Use qos attributes instead}}
|
|
_ = DispatchQueue.GlobalQueuePriority.default // expected-warning {{'default' is deprecated in watchOS: Use qos attributes instead}}
|
|
_ = DispatchQueue.GlobalQueuePriority.low // expected-warning {{'low' is deprecated in watchOS: Use qos attributes instead}}
|
|
let b = DispatchQueue.GlobalQueuePriority.background // expected-warning {{'background' is deprecated in watchOS: Use qos attributes instead}}
|
|
|
|
_ = DispatchQueue.global(priority:b) // expected-warning {{'global(priority:)' is deprecated in watchOS}}
|