URI handling code in Haskell available

Simon Marlow simonmar@microsoft.com
Thu, 6 Mar 2003 14:25:50 -0000


> Oops.  I didn't find that.  Thanks for the pointer.  (Thinks:=20
>  does it work with HUGS?)

It works with the latest hugs, November 2002 (use "hugs +N" to get the
hierarchical libraries).

> A significant amount of my work went into the test cases and=20
> matching the=20
> parsing code against the (revised work-in-progress) URI spec,=20
> so maybe=20
> there's some residual value there...?

When I wrote Network.URI I took the grammar from the RFC, and also a
bunch of test cases, which are in GHC's testsuite
(fptools/testsuite/tests/ghc-regress/lib/net/uri001.hs).  It might not
be up to date with the latest rev of the spec, however.  Any extra
testing you can do and/or comments you have on the API would be
appreciated.

One thing I know is questionable is that parseURI returns a Maybe URI,
when in fact there are no strings for which it can return Nothing
(*everything* is a valid URI, it seems!).

Cheers,
	Simon