package mirage

  1. Overview
  2. Docs
The MirageOS library operating system

Install

Dune Dependency

Authors

Maintainers

Sources

mirage-4.9.0.tbz
sha256=0c07d59eb52dc3d1506eb4121c4953104a12df79d08a0f0923c9b71e7474a026
sha512=666bf9ee20c9f9de058441f252f4f40ceec6a9ffd00e5cd3b7bfa9532fd65000aeb8a83f9e55586be98d0a86ea72f2dda94e924608135e3d63441359505de58a

doc/mirage.functoria/Functoria/Runtime_arg/index.html

Module Functoria.Runtime_argSource

Define runtime command-line arguments.

Sourcetype 'a arg

The type for command-line arguments that reads a value of type 'a.

Sourceval create : pos:(string * int * int * int) -> ?packages:Package.t list -> string -> 'a arg

create ~pos ?packages v is the runtime argument pointing to the value v. pos is expected to be __POS__. packages specifies in which opam package the value v is defined. This should be constrained to the correct type of the variable it is pointing to.

Sourcetype t

The type command-line arguments where the type of the value is abstract.

Sourceval packages : t -> Package.t list
Sourceval v : 'a arg -> t

v k is the k with its type hidden.

Sourcemodule Set : sig ... end

Set implements sets over t elements.

Code Serialization

Sourceval call : t Fmt.t

call fmt k outputs name () to fmt, where n is k's OCaml name.

Sourceval serialize : runtime_modname:string -> t Fmt.t

serialize ctx ppf k outputs the Cmdliner runes to parse command-line arguments represented by k at runtime.

Sourceval var_name : t -> string
OCaml

Innovation. Community. Security.