Instead:
for {
x <- monadEffect()
_ = directSideEffect(x)
} yield pureValue(x)
write just:
for {
x <- monadEffect()
directSideEffect(x)
} yield pureValue(x)
Haskell has similar feature in do notation with implicit >> operator. Scala compiler can optimise such for
expressions in proper way.