
1 Jun
2010
1 Jun
'10
3:20 p.m.
What does (stdin + stderr) `mod` stdout mean (result will be stdin).
In my GHCi (6.12.1) with System.IO, this fails because Handle is not a numeric type. What implementation are you using? The underlying object here is a Unix file descriptor, which is just a number. In that sense, stdin is 0, stdout is 1, and stderr is 2, so this would be (0 + 2) (mod 1) = 0.