Skip to content

Commit 1a2947d

Browse files
authored
Fix for Xcode 13 RC targeting macOS on Big Sur (#19)
Fixes #18.
1 parent ed8516e commit 1a2947d

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

Sources/CustomDump/Conformances/Foundation.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ import Foundation
44
import FoundationNetworking
55
#endif
66

7-
#if compiler(>=5.5)
7+
// NB: Xcode 13 does not include macOS 12 SDK
8+
#if compiler(>=5.5) && !os(macOS)
89
@available(iOS 15, macOS 12, tvOS 15, watchOS 8, *)
910
extension AttributedString: CustomDumpRepresentable {
1011
public var customDumpValue: Any {

Sources/CustomDump/Conformances/UserNotifications.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,8 @@
105105
}
106106
}
107107

108-
#if compiler(>=5.5)
108+
// NB: Xcode 13 does not include macOS 12 SDK
109+
#if compiler(>=5.5) && !os(macOS)
109110
@available(iOS 15, macOS 12, tvOS 15, watchOS 8, *)
110111
extension UNNotificationInterruptionLevel: CustomDumpStringConvertible {
111112
public var customDumpDescription: String {

Tests/CustomDumpTests/DumpTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ final class DumpTests: XCTestCase {
718718
func testFoundation() {
719719
var dump = ""
720720

721-
#if compiler(>=5.5)
721+
#if compiler(>=5.5) && !os(macOS)
722722
if #available(iOS 15, macOS 12, tvOS 15, watchOS 8, *) {
723723
dump = ""
724724
customDump(

0 commit comments

Comments
 (0)