Alexandru Nedelcu
05/06/2023, 8:36 AMRaise seems to be currently conflicting with other stuff in Kotlin (e.g., if you use Raise as the receiver type, you can't use anything else).
I have a validation function that I struggled to describe, I'm unsure if this is OK, or if there's any way I can improve it — trying to collect multiple validation errors from multiple fields, in order to produce a nice error message:
https://gist.github.com/alexandru/d5d6042278452d4817715b614a72be27
Btw, I struggled for more than half an hour with zipAndAccumulate because I imported the wrong one:
// Yikes, this isn't it
import arrow.core.Either.Companion.zipOrAccumulate
Documentation could be improved with some explicit imports, as IntellIJ IDEA can misfire.
Whole library is looking good, have made great use of it for managing resources.simon.vergauwen
05/06/2023, 10:42 AMEither if you cannot (or do not) want to use Raise as an extension receiver. The trade-off is having to use bind.simon.vergauwen
05/06/2023, 10:45 AMright necessary in the zipOrAccumulate?
And the return shouldn’t be there. Is that why the right is needed? 🤔
Super excited to see you venture into Arrow 😁 If been following you’re work since I’ve originally started learning FP in Scala. If you have any feedback I’d love to hear it! 🙏Alexandru Nedelcu
05/07/2023, 6:24 AM