behaviour change in getDirectoryContents in GHC 7.2?
Felipe Almeida Lessa
felipe.lessa at gmail.com
Tue Nov 1 16:48:19 CET 2011
On Tue, Nov 1, 2011 at 5:16 AM, Ganesh Sittampalam <ganesh at earth.li> wrote:
> I'm just investigating what we can do about a problem with darcs'
> handling of non-ASCII filenames on GHC 7.2.
>
> The issue is apparently that as of GHC 7.2, getDirectoryContents now
> tries to decode filenames in the current locale, rather than converting
> a stream of bytes into characters: http://bugs.darcs.net/issue2095
>
> I found an old thread on the subject:
> http://www.haskell.org/pipermail/haskell-cafe/2009-June/062795.html and
> some GHC tickets (e.g. http://hackage.haskell.org/trac/ghc/ticket/3300)
>
> Can anyone point me at the rationale and details of the change and/or
> suggest workarounds?
You could try using system-fileio [1], but by reading its source code
I guess that it may have the same bug (since it tries to decode what
the directory package gives). I'm CCing John Millikin, its
maintainer.
Cheers,
[1] http://hackage.haskell.org/packages/archive/system-fileio/0.3.2.1/doc/html/Filesystem.html#v:listDirectory
--
Felipe.
More information about the Glasgow-haskell-users
mailing list