<https://www.youtube.com/watch?v=CR5h2Wq1yPE&amp;a...
# arrow
c

https://www.youtube.com/watch?v=CR5h2Wq1yPE&amp;ab_channel=Intersect

This talk was the root of all evils. I was very proud to have built an application abstracting it from the final implementation, now all is suspend hahaha Now I can say that arrow allows you to build the same in a more simple and idiomatic way
r
The trick here is that suspend it’s actually a higher abstraction than those type class constrains since it can cover their use case already. You can still take your suspend program and go to an IO, like Mono, Single or any others, but why would you unless you have to interoperate? The compiler is already tracking the IO effect through suspend and ensuring the composition is safe and optimized
Much more optimized than any ADT based IO can ever achieve for all the sync cases
c
🙌
the only problem is that if you want to do functional programming in other languages, all this cannot be extrapolated. But I've had time to learn the basics these years ago haha
r
I think this is going to change once LOOM is widely adopted. Same reset / shift and continuation control can be implemented over LOOM and then it may be the predominant style in Java and other JVM langs.
c
what does LOOM stand for?
if you say this talk is the root of all evil, should i avoid watching it? :S
r
Loom is more than Thread non-blocking IO. It’s also possible to build reset / shift with it which is at the core of the continuation model in which you can describe effects and abilities like suspended monad bind as we do with Either and other datatypes. I can’t imagine that with such abilities libraries would ever choose to have or operate in terms of wrapped IOs for regular IO, suspend or F based programs. This ability would allow you to disregard flatMap, map and other functions related to working with a boxed value.
c
jajaja I recommend you to watch it, I learned a lot, although perhaps it's better to learn everything that it explains with other languages that support higher order kind
c
i decided to watch it anyway, i couldn't help myself
i'll be honest raul, what you said there is a bit beyond me, but I had not heard of it before. i will look at the link
r
@Chris Paul TLDR Loom will allow you to
F<A> -> A
not blocking where A is part of the continuation like async/await, and that is the same notion as Either.bind and others where we take A out of the box of IO or other types. No need to use boxed IOs or methods like flatMap or map over IO once continuations like this affect the encoding of libraries like it has done to Arrow.
c
ok I think i get it
i'm not massively familiar with async/await or co-routines
but from reading various things it soundsl ike you're moving away from higher kinds and so I think parts of the video will be less relevant
in the video he talked with a lot of certainty about higher kinds but that seems to have changed