mirror of
https://github.com/IBM/fp-go.git
synced 2025-11-29 22:38:29 +02:00
@@ -41,13 +41,13 @@ func SequenceArray[A any](tas []Lazy[A]) Lazy[[]A] {
|
||||
}
|
||||
|
||||
func MonadTraverseRecord[K comparable, A, B any](tas map[K]A, f func(A) Lazy[B]) Lazy[map[K]B] {
|
||||
return G.MonadTraverseRecord[Lazy[B], Lazy[map[K]B]](tas, f)
|
||||
return G.MonadTraverseRecord[Lazy[map[K]B]](tas, f)
|
||||
}
|
||||
|
||||
// TraverseRecord applies a function returning an [IO] to all elements in a record and the
|
||||
// transforms this into an [IO] of that record
|
||||
func TraverseRecord[K comparable, A, B any](f func(A) Lazy[B]) func(map[K]A) Lazy[map[K]B] {
|
||||
return G.TraverseRecord[Lazy[B], Lazy[map[K]B], map[K]A](f)
|
||||
return G.TraverseRecord[Lazy[map[K]B], map[K]A, Lazy[B]](f)
|
||||
}
|
||||
|
||||
// TraverseRecord applies a function returning an [IO] to all elements in a record and the
|
||||
|
||||
Reference in New Issue
Block a user