Re: [Haskell-cafe] Efficient way to break up a lazy bytestring

2006-12-29 Thread Ranjan Bagchi
On Dec 29, 2006, at 6:32 PM, Matthew Brecknell wrote: breakUp s | L.null s = [] | otherwise = h:(breakUp r) where (h,r) = L.splitAt 72 s Running this on the 2G file blows up the stack pretty quickly, taking the first 1 million records (there are 20M of them)

[Haskell-cafe] API for reading a big binary file

2006-12-21 Thread Ranjan Bagchi
Hi -- I'm still learning to use ghc effectively, and I'm trying to use it for more-or-less mundane programming tasks, hopefully in a way which is a lot more elegant than I'd do in Java or Perl. I've got a big [around a gigabyte] binary file, filled with identical binary structures

[Haskell-cafe] laziness

2006-12-09 Thread Ranjan Bagchi
be a pseudo random number generator), and take the first bit of it. Any help? Thanks, Ranjan Bagchi ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe