1
0
mirror of https://github.com/IBM/fp-go.git synced 2025-08-10 22:31:32 +02:00

fix: add more examples

Signed-off-by: Dr. Carsten Leue <carsten.leue@de.ibm.com>
This commit is contained in:
Dr. Carsten Leue
2023-08-11 16:26:15 +02:00
parent bb630810fc
commit e9f03e2d26
31 changed files with 11709 additions and 11035 deletions

View File

@@ -182,7 +182,7 @@ func FromPredicate[E, A any](pred func(A) bool, onFalse func(A) E) func(A) Eithe
}
}
func FromNillable[E, A any](e E) func(*A) Either[E, *A] {
func FromNillable[A, E any](e E) func(*A) Either[E, *A] {
return FromPredicate(F.IsNonNil[A], F.Constant1[*A](e))
}