Wolfgang Jeltsch wrote: > > However, a simple and fairly generic mechanism for doing this is: > > > > 1. Read in a list of "Char"s with the standard I/O functions. > > This will most likely cause problems under Windows. The reason is that the > standard I/O functions are intended for reading and writing text, and that's > why under Windows the sequence CRLF (#0D#0A) is interpreted as a single LF > (#0A) and EOF (#1A) is interpreted as the end of the file.
Good point. Both GHC and Hugs provide openFileEx, which allows files to be read in binary mode (without EOL/EOF translations). -- Glynn Clements <[EMAIL PROTECTED]> _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell