HTTP types: headers, status codes, methods, bodies, MIME types
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

ocaml-http: enable MDX on lib/http_date.mli

Run mdx on lib/http_date.mli so the {[ ... ]} odoc block now
type-checks. The block had ocamlformat-collapsed [parse ... (* RFC
1123 *) parse ...] runs that the toploop reads as a single chained
function application. Replaced with three explicit
`assert (Option.is_some ...)` lines, one per documented date format.

+14 -3
+4
lib/dune
··· 12 12 nox-crypto-rng 13 13 uri 14 14 fmt)) 15 + 16 + (mdx 17 + (files http_date.mli) 18 + (libraries nox-http))
+10 -3
lib/http_date.mli
··· 22 22 23 23 Examples: 24 24 {[ 25 - parse "Sun, 06 Nov 1994 08:49:37 GMT" (* RFC 1123 *) parse 26 - "Sunday, 06-Nov-94 08:49:37 GMT" (* RFC 850 *) parse 27 - "Sun Nov 6 08:49:37 1994" (* asctime *) 25 + let () = 26 + assert ( 27 + Option.is_some (Http.Http_date.parse "Sun, 06 Nov 1994 08:49:37 GMT")) 28 + 29 + let () = 30 + assert ( 31 + Option.is_some (Http.Http_date.parse "Sunday, 06-Nov-94 08:49:37 GMT")) 32 + 33 + let () = 34 + assert (Option.is_some (Http.Http_date.parse "Sun Nov 6 08:49:37 1994")) 28 35 ]} *)