julian
06/09/2020, 5:55 PMf3 . It seems like there might be a named pattern for what it's doing. It kind of behaves like partially, except it defers the partial application till later. Then it partially applies to f2 the result of executing the deferred function (when that happens).
If such a pattern exists, what's its name? Do helper functions already exist in Arrow to do this for me? Basically, is there a better way?
Thanks much!raulraja
06/09/2020, 9:53 PMjulian
06/09/2020, 10:04 PMcurry function in core one has to respect the order of the parameters of the function being curried.julian
06/09/2020, 10:06 PMval r1 = Reader { e: E -> Id(f1(p3 = e)) }
val r2 = r1.map { f -> Reader { a: A -> Id(f(p1 = a)) } }
val d = r2.runId(E()).runId(A())(F())
I don't know what I'm doing. 🤣 I'm just kinda pounding at the keyboard and seeing what happens.raulraja
06/09/2020, 10:06 PMjulian
06/09/2020, 10:09 PMraulraja
06/09/2020, 10:13 PMfun E.r1() = f1(...)
fun A.r2() = r1(...)
fun d() = E().r2(...julian
06/09/2020, 10:24 PM