ANN: MissingH 0.7.2 with GZip

David Roundy droundy at
Sun Dec 5 08:01:27 EST 2004

On Sat, Dec 04, 2004 at 05:42:30PM -0600, John Goerzen wrote:
> Hello,
> I'm pleased to announce the release of MissingH 0.7.2, available from
> This release incorporates Ian Lynagh's pure-Haskell Inflate algorithm,
> and CRC-32 and GZip file parsers of my own design, to make a
> pure-Haskell solution[1] to decompressing .gz files.  At present, it
> is rather slow, as there has been little effort to optimize any of the
> three components.  Patches to address the speed will be happily
> applied.  The Inflate and CRC32 algorithms also provide the necessary
> support to be able to handle ZIP files.  I plan to introduce ZIP and
> tar file support in upcoming releases of MissingH.

The FileArchive.GZip module is interesting, but I'm not sure I care for the
interface.  Wouldn't it be better for

decompress :: String -> (String, Maybe GZipError)

to be

decompress :: [Word8] -> Either GZipError [Word8]

And I'm not sure how hDecompress works.  Could we use this with a pipe to
read a gzipped file, or does it have to be able to synchronously write the
entire file to the output handle?

What I'd really like would be

openGZippedFile :: IOMode -> FilePath -> IO Handle

And of course, speed is an issue, so an optional zlib backend would be
double-nice (or a really well-optimized decompressor).  For now, I guess
I'll stick with my tried and true (and butt ugly) zlib ffi interface, which
uses threads and pipes to implement a gzOpenFile.

Actually, I see that compression is not implemented either...
David Roundy

More information about the Libraries mailing list