Skip to content

Commit 17e133c

Browse files
committed
Link to Ocamlary from index of pages
and add an example of comments associated to polymorphic variants Signed-off-by: Paul-Elliot <[email protected]>
1 parent 745ba87 commit 17e133c

File tree

5 files changed

+10
-3
lines changed

5 files changed

+10
-3
lines changed

doc/driver.mld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ let dep_libraries =
269269
let odoc_libraries = [
270270
"odoc_xref_test"; "odoc_xref2"; "odoc_odoc"; "odoc_html_support_files";
271271
"odoc_model_desc"; "odoc_model"; "odoc_manpage"; "odoc_loader";
272-
"odoc_latex"; "odoc_html"; "odoc_document"; "odoc_examples" ];;
272+
"odoc_latex"; "odoc_html"; "odoc_document"; "odoc_examples"; "ocamlary" ];;
273273

274274
let all_libraries = dep_libraries @ odoc_libraries;;
275275

doc/library_mlds/dune

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@
1111
odoc_model_desc
1212
odoc_odoc
1313
odoc_xref2
14-
odoc_xref_test))
14+
odoc_xref_test
15+
ocamlary))

doc/library_mlds/ocamlary.mld

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{0 Ocamlary}
2+
3+
A demonstration of the rendering of most of the OCaml constructs {!module-Ocamlary}.

doc/odoc.mld

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,4 +53,5 @@ The main other pages of this site:
5353
- {!page-dune} Dune
5454
- {!page-parent_child_spec} Parent/Child specification
5555
- {!page-interface} Interface guarantees
56+
- {!page-ocamlary} A demonstration of the rendering of most of the OCaml constructs
5657

src/ocamlary/ocamlary.mli

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,9 @@ type variant =
430430
(** This comment is also for [variant]. *)
431431

432432
(** This comment is for [poly_variant]. *)
433-
type poly_variant = [ `TagA | `ConstrB of int ]
433+
type poly_variant =
434+
[ `TagA (** This is a comment for [`TagA] *)
435+
| `ConstrB of int (** This is a comment for [`ConstrB] *) ]
434436
(** Wow! It was a polymorphic variant! *)
435437

436438
(** This comment is for [full_gadt]. *)

0 commit comments

Comments
 (0)