package mdx
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=32a08398100afd2d2e7988bc3b45c9b69971271f7ab708851ded3843c9470661
sha512=b16d257fa9e515318dba22a1eb7a19f59c40414cdbeaaee0e48b6384f74b56497fd0e547b234a1329b7334d2fbdbb7c256fdf8406ae1d1f85b49dd5c5025eba2
doc/mdx/Mdx/Block/index.html
Module Mdx.Block
Source
Code blocks headers.
Code blocks.
type ocaml_value = {
env : Ocaml_env.t;
(*
*)env
is the name given to the environment where tests are run.non_det : Label.non_det option;
errors : Output.t list;
(*
*)header
defines whether a header was specified for the block.header : Header.t option;
}
type toplevel_value = {
env : Ocaml_env.t;
(*
*)env
is the name given to the environment where tests are run.non_det : Label.non_det option;
}
type include_ocaml_file = {
part_included : string option;
(*
*)part_included
is the part of the file to synchronize with. If lines is not specified synchronize the whole file.
}
type include_value = {
file_included : string;
(*
*)file_included
is the name of the file to synchronize with.file_kind : include_file_kind;
}
type value =
| Raw of raw_value
| OCaml of ocaml_value
| Cram of cram_value
| Toplevel of toplevel_value
| Include of include_value
The type for block values.
The type for sections.
type t = {
loc : Location.t;
section : section option;
dir : string option;
labels : Label.t list;
legacy_labels : bool;
contents : string list;
skip : bool;
version_enabled : bool;
(*Whether the current OCaml version complies with the block's version.
*)set_variables : (string * string) list;
unset_variables : string list;
value : value;
}
The type for supported code blocks.
val mk_include :
loc:Location.t ->
section:section option ->
labels:Label.t list ->
(t, [ `Msg of string ]) result
mk_include
builds an include block from a comment <!-- $MDX ... -->
that is not followed by a code block ``` ... ```
.
Printers
pp_header
pretty-prints full block headers with the labels.
pp_footer
pretty-prints block footer.
Accessors
Whether a block's command or output is non-deterministic.
set_variable t
is the list of environment variable to set and their values
unset_variable t
is the list of environment variable to unset