From 7e7ae4aa099777fd8d5a4398d55d628fe2f9ccc5 Mon Sep 17 00:00:00 2001 From: Max Goedjen Date: Tue, 25 Oct 2022 14:42:40 -0700 Subject: [PATCH] Add equatable conformance when value is equatable (#1565) --- .../ComposableArchitecture/Effects/ConcurrencySupport.swift | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Sources/ComposableArchitecture/Effects/ConcurrencySupport.swift b/Sources/ComposableArchitecture/Effects/ConcurrencySupport.swift index 530a7305d565..38a665bcf8ad 100644 --- a/Sources/ComposableArchitecture/Effects/ConcurrencySupport.swift +++ b/Sources/ComposableArchitecture/Effects/ConcurrencySupport.swift @@ -395,3 +395,9 @@ public struct UncheckedSendable: @unchecked Sendable { _modify { yield &self.value[keyPath: keyPath] } } } + +extension UncheckedSendable: Equatable where Value: Equatable { + public static func == (lhs: UncheckedSendable, rhs: UncheckedSendable) -> Bool { + lhs.value == rhs.value + } +}