From eb3c3d8b721618d7400f0fd2178b65057d6e1c24 Mon Sep 17 00:00:00 2001 From: nnabeyang Date: Sat, 26 Oct 2024 09:13:21 +0900 Subject: [PATCH 1/2] Updated fatalError message in DateComponents bridging method to reflect correct type information. --- Sources/Foundation/DateComponents.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/Foundation/DateComponents.swift b/Sources/Foundation/DateComponents.swift index 95865d25bb..3f87791aab 100644 --- a/Sources/Foundation/DateComponents.swift +++ b/Sources/Foundation/DateComponents.swift @@ -38,7 +38,7 @@ extension DateComponents : _ObjectiveCBridgeable { public static func _forceBridgeFromObjectiveC(_ dateComponents: NSDateComponents, result: inout DateComponents?) { if !_conditionallyBridgeFromObjectiveC(dateComponents, result: &result) { - fatalError("Unable to bridge \(DateComponents.self) to \(self)") + fatalError("Unable to bridge \(NSDateComponents.self) to \(self)") } } From a6749777e06003789549982364f7c7ea73b2a458 Mon Sep 17 00:00:00 2001 From: nnabeyang Date: Sat, 26 Oct 2024 09:19:45 +0900 Subject: [PATCH 2/2] Aligned fatalError message in Notification bridging method with the format used in other bridging methods. --- Sources/Foundation/Notification.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/Foundation/Notification.swift b/Sources/Foundation/Notification.swift index 936d28caf7..b125bead13 100644 --- a/Sources/Foundation/Notification.swift +++ b/Sources/Foundation/Notification.swift @@ -111,7 +111,7 @@ extension Notification : _ObjectiveCBridgeable { public static func _forceBridgeFromObjectiveC(_ x: NSNotification, result: inout Notification?) { if !_conditionallyBridgeFromObjectiveC(x, result: &result) { - fatalError("Unable to bridge type") + fatalError("Unable to bridge \(NSNotification.self) to \(self)") } }