Skip to content

Commit 8e769fa

Browse files
authored
Update FieldParser.swift availability guard (#63)
Update FieldParser.swift availability guard for ``` String(unsafeUninitializedCapacity: unescapedBytes.count) ``` which is only available on Mac Catalyst 14.0 or later
1 parent ddbbf18 commit 8e769fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/RawStructuredFieldValues/FieldParser.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -639,7 +639,7 @@ extension String {
639639
// We assume the string is previously validated, so the escapes are easily removed. See the doc comment for
640640
// `StrippingStringEscapesCollection` for more details on what we're doing here.
641641
let unescapedBytes = StrippingStringEscapesCollection(bytes, escapes: escapes)
642-
if #available(macOS 10.16, macCatalyst 10.16, iOS 14.0, watchOS 7.0, tvOS 14.0, *) {
642+
if #available(macOS 10.16, macCatalyst 14.0, iOS 14.0, watchOS 7.0, tvOS 14.0, *) {
643643
return String(unsafeUninitializedCapacity: unescapedBytes.count) { innerPtr in
644644
let (_, endIndex) = innerPtr.initialize(from: unescapedBytes)
645645
return endIndex

0 commit comments

Comments
 (0)