Y
Hacker News
new
|
ask
|
show
|
jobs
by
kenko
4152 days ago
Why `Either Text Text`? What if you're interested in both stdout and stderr?
1 comments
Gabriel439
4152 days ago
Then you can do this:
fmap (either id id) (both ...)
... which is equivalent to:
x <- both ... return (case x of Left txt -> txt Right txt -> txt)
That removes the `Either` tag and fuses them into a single stream.
link