3 ms·
Specialized in the sense of a more restricted type. From your answer, it seems like "no" - though my Scala is superficial and rusty. The Haskell equivalent is
by dllthomas 12y ago
Specialized in the sense of a more restricted type. From your answer, it seems like "no" - though my Scala is superficial and rusty.
The Haskell equivalent is join :: Monad m => m (m a) -> m a
We also have the equivalent specialized to lists: concat :: [[a]] -> [a]
And as you say, join = bind id = (>>= id).
Incidentally, in math that function is the "eta" in the triple representing a monad.