I would like to combine a Kotlin extension function on some receiver class Receiver
with arrow-kt's either comprehension. In a regular Kotlin extension function, this
binds to the receiver object; however, the either-comprehension EitherEffect
shadows the Receiver this
:
suspend fun Receiver.myFun(param: String): Either<Throwable, String> = either {
this.someMethod(...).bind() // Cannot access Receiver.someMethod, <this> is bound to EitherEffect
...
}
How can I access the receiver context within arrow's either-comprehension block (or any other monadic comprehension block)?