mirror of
https://github.com/IBM/fp-go.git
synced 2025-11-23 22:14:53 +02:00
fix: introduce Kleisli type
Signed-off-by: Dr. Carsten Leue <carsten.leue@de.ibm.com>
This commit is contained in:
9
v2/lazy/types.go
Normal file
9
v2/lazy/types.go
Normal file
@@ -0,0 +1,9 @@
|
||||
package lazy
|
||||
|
||||
type (
|
||||
// Lazy represents a synchronous computation without side effects
|
||||
Lazy[A any] = func() A
|
||||
|
||||
Kleisli[A, B any] = func(A) Lazy[B]
|
||||
Operator[A, B any] = Kleisli[Lazy[A], B]
|
||||
)
|
||||
Reference in New Issue
Block a user