
10 May
2007
10 May
'07
3:24 a.m.
| Also if stmt = | | SomeModule.prettyPrinter "foobar" | | and SomeModule contains | | prettyPrinter x = putStrLn $ "Pretty: " ++ x | | then the let binding will not catch it. Indeed, that's exactly what I meant in my original msg. I have always thought it ugly that stdin and stdout are top-level definitions. I want to be able to say withStdout :: Handle -> IO a -> IO a so that (withStdout h a) runs 'a' but sends all std-out output to h. Haskell should support this. Starting a whole OS process to redirect stdout must surely be overkill! (But maybe that is what you have to do today.) S