3 ms·
Scala's for-comprehension work quite good. It is part of idiomatic Scala and works for all monads. for { thing <- whatever1 thing2 <- mightFail } y
by esarbe 7y ago
Scala's for-comprehension work quite good. It is part of idiomatic Scala and works for all monads.
for {
thing <- whatever1
thing2 <- mightFail
} yield (thing, thing2)