You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/FSharpPlus/Control/Applicative.fs
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,7 @@ type Apply =
27
27
static member ``<*>`` (f:_ [],x:'T [],[<Optional>]_output:'U [],[<Optional>]_mthd:Apply)= Array.apply f x : 'U []
28
28
static member ``<*>`` (f:'r ->_ ,g:_ ->'T ,[<Optional>]_output:'r ->'U ,[<Optional>]_mthd:Apply)=fun x ->letf' = f x in f' (g x): 'U
29
29
static member inline ``<*>`` ((a:'Monoid,f),(b:'Monoid,x:'T),[<Optional>]_output:'Monoid * 'U ,[<Optional>]_mthd: Apply)=(Plus.Invoke a b, f x): 'Monoid *'U
30
+
static member inline ``<*>`` (struct(a:'Monoid,f),struct(b:'Monoid,x:'T),[<Optional>]_output:struct ('Monoid * 'U),[<Optional>]_mthd:Apply)=struct(Plus.Invoke a b, f x):struct('Monoid * 'U)
30
31
#if!FABLE_COMPILER
31
32
static member ``<*>`` (f:Task<_>,x:Task<'T>,[<Optional>]_output:Task<'U>,[<Optional>]_mthd:Apply)= Task.apply f x : Task<'U>
32
33
#endif
@@ -82,6 +83,7 @@ type Lift2 =
82
83
static memberLift2(f,(x ,y ),_mthd:Lift2)= Array.lift2 f x y
83
84
static memberLift2(f,(x:'R ->'T ,y:'R ->'U ),_mthd:Lift2)=fun a -> f (x a)(y a)
84
85
static member inlineLift2(f,((a:'Monoid,x:'T),(b:'Monoid,y:'U)),_mthd:Lift2)= Plus.Invoke a b, f x y
86
+
static member inlineLift2(f,(struct(a:'Monoid,x:'T),struct(b:'Monoid,y:'U)),_mthd:Lift2)=struct(Plus.Invoke a b, f x y)
85
87
#if!FABLE_COMPILER
86
88
static memberLift2(f,(x:Task<'T>,y:Task<'U>),_mthd:Lift2)= Task.map2 f x y
Copy file name to clipboardExpand all lines: src/FSharpPlus/Control/Bifoldable.fs
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,7 @@ type BifoldMap =
12
12
static memberBifoldMap(x:Result<'T2,'T1>,f,g,_impl:BifoldMap)=match x with Error x -> f x | Ok x -> g x : 'U
13
13
static memberBifoldMap(x:Choice<'T2,'T1>,f,g,_impl:BifoldMap)=match x with Choice2Of2 x -> f x | Choice1Of2 x -> g x : 'U
14
14
static member inlineBifoldMap((x:'T1,y:'T2),f,g,_impl:BifoldMap)= Plus.Invoke (f x)(g y): 'U
15
+
static member inlineBifoldMap(struct(x:'T1,y:'T2),f,g,_impl:BifoldMap)= Plus.Invoke (f x)(g y): 'U
15
16
16
17
static member inlineInvoke(f:'T1->'U)(g:'T2->'U)(source:'``Bifoldable<T1,T2>``):'U =
17
18
let inlinecall(a:^a,b:^b)=((^aor^b):(static memberBifoldMap:_*_*_*_->_) b,f,g,a)
@@ -30,6 +31,7 @@ type Bifold =
30
31
static member inlineBifold(x:Result<'T2,'T1>,f:'S->'T1->'S,g :'S->'T2->'S,z:'S,_impl:Bifold)=match x with Error x -> f z x | Ok x -> g z x
31
32
static member inlineBifold(x:Choice<'T2,'T1>,f:'S->'T1->'S,g :'S->'T2->'S,z:'S,_impl:Bifold)=match x with Choice2Of2 x -> f z x | Choice1Of2 x -> g z x
32
33
static member inlineBifold((x:'T1,y:'T2),f:'S->'T1->'S,g :'S->'T2->'S,z:'S,_impl:Bifold)= g (f z x) y
34
+
static member inlineBifold(struct(x:'T1,y:'T2),f:'S ->'T1 ->'S,g :'S ->'T2 ->'S,z:'S,_impl:Bifold)= g (f z x) y
33
35
34
36
static member inlineInvoke(f:'S->'T1->'S)(g:'S->'T2->'S)(z:'S)(source:'``Bifoldable<'T1,'T2>``):'S =
35
37
let inlinecall(a:^a,b:^b)=((^aor^b):(static memberBifold:_*_*_*_*_->_) b,f,g,z,a)
@@ -48,6 +50,7 @@ type BifoldBack =
48
50
static member inlineBifoldBack(x:Result<'T2,'T1>,f:'T1->'S->'S,g :'T2->'S->'S,z:'S,_impl:BifoldBack)=match x with Error x -> f x z | Ok x -> g x z
49
51
static member inlineBifoldBack(x:Choice<'T2,'T1>,f:'T1->'S->'S,g :'T2->'S->'S,z:'S,_impl:BifoldBack)=match x with Choice2Of2 x -> f x z | Choice1Of2 x -> g x z
50
52
static member inlineBifoldBack((x:'T1,y:'T2),f:'T1->'S->'S,g :'T2->'S->'S,z:'S,_impl:BifoldBack)=(f x (g y z))
53
+
static member inlineBifoldBack(struct(x:'T1,y:'T2),f:'T1 ->'S ->'S,g :'T2 ->'S ->'S,z:'S,_impl:BifoldBack)=(f x (g y z))
51
54
52
55
static member inlineInvoke(f:'T1->'S->'S)(g:'T2->'S->'S)(z:'S)(source:'``Bifoldable<'T1,'T2>``):'S =
53
56
let inlinecall(a:^a,b:^b)=((^aor^b):(static memberBifoldBack:_*_*_*_*_->_) b,f,g,z,a)
@@ -66,6 +69,7 @@ type Bisum =
66
69
static memberBisum(x:Result<_,_>,_impl:Bisum)=match x with Ok x -> x | Error x -> x
67
70
static memberBisum(x:Choice<_,_>,_impl:Bisum)=match x with Choice1Of2 x -> x | Choice2Of2 x -> x
68
71
static member inlineBisum((x,y),_impl:Bisum)= Plus.Invoke x y
72
+
static member inlineBisum(struct(x,y),_impl:Bisum)= Plus.Invoke x y
69
73
70
74
static member inlineInvoke(source:'``Bifoldable<'T1,'T2>``):'U =
71
75
let inlinecall(a:^a,b:^b)=((^aor^b):(static memberBisum:_*_->_) b,a)
0 commit comments