| In 7.1, the Report says of getChar, getContents and friends: | | "By default, these input functions echo to standard output." | | This would mean that the example given: | | main = interact (filter isAscii) | | would print the input with all ASCII characters duplicated. | | Surely it should say that if the standard input is a terminal device the | input is echoed on that device. Or maybe the sentence should be deleted.
Ross's speaks truth. In fact, the overall behaviour of a Haskell program when used from a terminal ought to be predicable regardless of OS. And indeed one expects the behaviour to differ depending on whether stdin is a terminal or a file. So I propose to adopt Ross's modification: "Surely it should say that if the standard input is a terminal device the input is echoed on that device." This describes what Haskell implementations actually do, and it describes the desired behaviour. All this is about the Language Report. In the Library Report, it says that "getLine" is sort for "hGetLine stdin". So that implies that If the standard input (stdin) is a terminal device, any input on stdin is echoed on that device So, for consistency, I propose to add that to the IO chapter of the library report. Does that seem right? It is very late in the day to be fiddling with the Report. I'll emit an update in a separate message. Simon _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell