adding doctests.

This commit is contained in:
Kazu Yamamoto 2013-11-01 13:49:40 +09:00
parent e087d4349a
commit 9e5f743761

View File

@ -32,6 +32,12 @@ parseHeaderLines (firstLine:otherLines) = do
----------------------------------------------------------------
-- |
--
-- >>> parseRequestLine "GET / HTTP/1.1"
-- ("GET","/","",HTTP/1.1)
-- >>> parseRequestLine "POST /cgi/search.cgi?key=foo HTTP/1.0"
-- ("POST","/cgi/search.cgi","?key=foo",HTTP/1.0)
parseRequestLine :: ByteString
-> IO (ByteString, ByteString, ByteString, H.HttpVersion)
parseRequestLine s =