[Haskell-cafe] Filesystem questions
magnus at therning.org
Sat Oct 13 18:56:59 EDT 2007
On Sat, Oct 13, 2007 at 23:27:13 +0200, Yitzchak Gale wrote:
>Andrew Coppin wrote:
>>> Is there a way to get rid of "." and ".." in the results?
>Brandon S. Allbery wrote:
>> Manual filtering is always required, whether C, Perl, Haskell, etc.
>> I dunno, maybe python filters them for you or something.
>Correct, Python filters them out. This is clearly the correct
>behavior. That is what is needed in the vast majority
>of cases, and it is still reasonably easy to deal
>with the unusual cases.
>It is too bad that Haskell is among the many languages
>that get this wrong.
>Python also has os.walk, a very convenient functional (sort of)
>tool for recursing through directories. (It sounds trivial, but
>it is not, there are enough annoying details that this function
>saves huge amounts of time.) Very embarrassing that Haskell
>is missing this.
>How about a built-in function that represents a directory tree
>as a lazy Data.Tree?
Not really what you're looking for, but hopefully it's a good place to
Magnus Therning (OpenPGP: 0xAB4DFBA4)
magnus＠therning．org Jabber: magnus．therning＠gmail．com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20071013/36a8eba6/attachment.bin
More information about the Haskell-Cafe