1
0
mirror of https://github.com/IBM/fp-go.git synced 2025-11-23 22:14:53 +02:00

fix: modernize codebase

Signed-off-by: Dr. Carsten Leue <carsten.leue@de.ibm.com>
This commit is contained in:
Dr. Carsten Leue
2025-11-15 17:00:22 +01:00
parent ab868315d4
commit ed108812d6
51 changed files with 896 additions and 374 deletions

View File

@@ -17,7 +17,7 @@ type (
// computation := lazy.Of(42)
//
// // Transform it (not evaluated yet)
// doubled := lazy.Map(func(x int) int { return x * 2 })(computation)
// doubled := lazy.Map(N.Mul(2))(computation)
//
// // Evaluate when needed
// result := doubled() // 84
@@ -52,7 +52,7 @@ type (
// Example:
//
// // An operator that doubles the value in a lazy computation
// doubleOp := lazy.Map(func(x int) int { return x * 2 })
// doubleOp := lazy.Map(N.Mul(2))
//
// // Apply it to a lazy computation
// result := doubleOp(lazy.Of(5))() // 10