Skip to content

Commit d4564e4

Browse files
committed
[stdlib] Define availability for SwiftStdlib 6.0
1 parent b593062 commit d4564e4

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

stdlib/public/ClangOverlays/float.swift.gyb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ public let FLT_RADIX = Double.radix
2525
// significand bit, but Swift does not. Neither is really right or wrong.
2626
@available(swift, deprecated: 3.0, message: "Please use '${type}.significandBitCount + 1'.")
2727
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
28-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
28+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
2929
public let ${prefix}_MANT_DIG = ${type}.significandBitCount + 1
3030

3131
// Where does the 1 come from? C models floating-point numbers as having a
@@ -34,32 +34,32 @@ public let ${prefix}_MANT_DIG = ${type}.significandBitCount + 1
3434
// as well.
3535
@available(swift, deprecated: 3.0, message: "Please use '${type}.greatestFiniteMagnitude.exponent + 1'.")
3636
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
37-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
37+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
3838
public let ${prefix}_MAX_EXP = ${type}.greatestFiniteMagnitude.exponent + 1
3939

4040
@available(swift, deprecated: 3.0, message: "Please use '${type}.leastNormalMagnitude.exponent + 1'.")
4141
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
42-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
42+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
4343
public let ${prefix}_MIN_EXP = ${type}.leastNormalMagnitude.exponent + 1
4444

4545
@available(swift, deprecated: 3.0, message: "Please use '${type}.greatestFiniteMagnitude' or '.greatestFiniteMagnitude'.")
4646
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
47-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
47+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
4848
public let ${prefix}_MAX = ${type}.greatestFiniteMagnitude
4949

5050
@available(swift, deprecated: 3.0, message: "Please use '${type}.ulpOfOne' or '.ulpOfOne'.")
5151
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
52-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
52+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
5353
public let ${prefix}_EPSILON = ${type}.ulpOfOne
5454

5555
@available(swift, deprecated: 3.0, message: "Please use '${type}.leastNormalMagnitude' or '.leastNormalMagnitude'.")
5656
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
57-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
57+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
5858
public let ${prefix}_MIN = ${type}.leastNormalMagnitude
5959

6060
@available(swift, deprecated: 3.0, message: "Please use '${type}.leastNonzeroMagnitude' or '.leastNonzeroMagnitude'.")
6161
@available(macOS 10.9, iOS 7.0, watchOS 2.0, tvOS 9.0, *)
62-
@_originallyDefinedIn(module: "Darwin", macOS 9999, iOS 9999, watchOS 9999, tvOS 9999)
62+
@_originallyDefinedIn(module: "Darwin", macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0)
6363
public let ${prefix}_TRUE_MIN = ${type}.leastNonzeroMagnitude
6464

6565
% if type == "Float80":

stdlib/public/core/ErrorType.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ func _willThrowTypedImpl<E: Error>(_ error: E)
195195
@_alwaysEmitIntoClient
196196
@_silgen_name("swift_willThrowTyped")
197197
public func _willThrowTyped<E: Error>(_ error: E) {
198-
if #available(macOS 9999, iOS 9999, watchOS 9999, tvOS 9999, visionOS 9999, *) {
198+
if #available(macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0, *) {
199199
_willThrowTypedImpl(error)
200200
}
201201
}

utils/availability-macros.def

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ SwiftStdlib 5.7:macOS 13.0, iOS 16.0, watchOS 9.0, tvOS 16.0
3535
SwiftStdlib 5.8:macOS 13.3, iOS 16.4, watchOS 9.4, tvOS 16.4
3636
SwiftStdlib 5.9:macOS 14.0, iOS 17.0, watchOS 10.0, tvOS 17.0
3737
SwiftStdlib 5.10:macOS 14.4, iOS 17.4, watchOS 10.4, tvOS 17.4, visionOS 1.1
38-
SwiftStdlib 6.0:macOS 9999, iOS 9999, watchOS 9999, tvOS 9999, visionOS 9999
38+
SwiftStdlib 6.0:macOS 15.0, iOS 18.0, watchOS 11.0, tvOS 18.0, visionOS 2.0
3939
# TODO: Also update ASTContext::getSwift510Availability when needed
4040
# TODO: Also update ASTContext::getSwift60Availability when needed
4141

0 commit comments

Comments
 (0)