> What is the limit on open files, and why? I think it'd be nice to > just schedule a huge amount of IO operations, and have them all be > performed when required (i.e. when the FM is first accessed). > Apparently, my addDir took the trouble to open the files, but not > generate the FMs -- any idea why?
The limit is imposed by the OS, and is usally tunable. Try 'ulimit -a' on a Unix box (the command might be different depending on your shell; check the manpage). readFile must *open* the file strictly, because it has to raise an exception if any errors occur. But thereafter, all reading is done lazilly. If you also want the open to be lazy, then use unsafePerformIO. It's Your Funeral, as we say in GHC land ;-) Cheers, Simon _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell