Posix.getFileStatus
George Russell
ger at tzi.de
Thu Feb 27 12:40:48 EST 2003
(1) I think Posix.getFileStatus should respond to a file which isn't there with something rather more helpful than
"system error". For example, a "No such file or directory" message.
(2) The logical way of spotting whether a file is actually there is the
queryFile function, documented for example here:
http://haskell.cs.yale.edu/ghc/docs/latest/html/hslibs/files-and-directories.html
But sadly the queryFile function does not appear to be in the Posix module! At least not for
ghc5.04.2.
Good thing there's a Directory.doesFileExist function! Of course that's not quite the same, since it
only checks if there is a normal file of that name (it returns False for a directory).
More information about the Glasgow-haskell-bugs
mailing list