Skip to content

[NFC] Be Explicit About tvOS Feature Availability #996

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 27, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 1 addition & 14 deletions Sources/SwiftDriver/Utilities/Triple+Platforms.swift
Original file line number Diff line number Diff line change
Expand Up @@ -344,20 +344,6 @@ extension Triple {
self.nonDarwin = nonDarwin
}

/// Describes the availability of a feature that is supported on multiple platforms,
/// but is tied to a particular version.
///
/// If `tvOS` availability is omitted, it will be set to be the same as `iOS`.
public init(
macOS: Availability,
iOS: Availability,
watchOS: Availability,
nonDarwin: Bool = false
) {
self.init(macOS: macOS, iOS: iOS, tvOS: iOS, watchOS: watchOS,
nonDarwin: nonDarwin)
}

/// Returns the version when the feature was introduced on the specified Darwin
/// platform, or `.unavailable` if the feature has not been introduced there.
public subscript(darwinPlatform: DarwinPlatform) -> Availability {
Expand Down Expand Up @@ -404,6 +390,7 @@ extension Triple.FeatureAvailability {
static let nativeARC = Self(
macOS: .available(since: Triple.Version(10, 11, 0)),
iOS: .available(since: Triple.Version(9, 0, 0)),
tvOS: .available(since: Triple.Version(9, 0, 0)),
watchOS: .availableInAllVersions
)
// When updating the versions listed here, please record the most recent
Expand Down