Skip to content

Commit 64e91bd

Browse files
committed
Ambiguate KeyValuePair in Map
1 parent bbb72b4 commit 64e91bd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/FSharpPlus/Control/Functor.fs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ type Map =
8989
static member Map ((x: Result<_,'E> , f: 'T->'U), _mthd: Map) = Result.map f x
9090
static member Map ((x: Choice<_,'E> , f: 'T->'U), _mthd: Map) = Choice.map f x
9191
static member Map ((KeyValue(k, x) , f: 'T->'U), _mthd: Map) = KeyValuePair (k, f x)
92+
static member Map ((x: KeyValuePair2<_, _> , f: 'T->'U), _mthd: Map) = let k, x = x.Key, x.Value in KeyValuePair2 (k, f x)
9293
static member Map ((x: Map<'Key,'T> , f: 'T->'U), _mthd: Map) = Map.map (const' f) x : Map<'Key,'U>
9394
static member Map ((x: Dictionary<_,_> , f: 'T->'U), _mthd: Map) = Dictionary.map f x : Dictionary<'Key,'U>
9495
#if !FABLE_COMPILER

0 commit comments

Comments
 (0)