package catala

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type backend_lang =
  1. | En
  2. | Fr
  3. | Pl

Configuration globals

val source_files : string list ref

Source files to be compiled

val locale_lang : backend_lang ref
val contents : string ref
val debug_flag : bool ref
val style_flag : bool ref

Styles the terminal output

val optimize_flag : bool ref
val max_prec_digits : int ref

Max number of digits to show for decimal results

val trace_flag : bool ref
val disable_counterexamples : bool ref

Disables model-generated counterexamples for proofs that fail.

val avoid_exceptions_flag : bool ref

Avoids using try ... with exceptions when compiling the default calculus.

CLI terms

val file : string Cmdliner.Term.t
val debug : bool Cmdliner.Term.t
val unstyled : bool Cmdliner.Term.t
val trace_opt : bool Cmdliner.Term.t
val wrap_weaved_output : bool Cmdliner.Term.t
val backend : string Cmdliner.Term.t
type backend_option =
  1. | Dcalc
  2. | Html
  3. | Interpret
  4. | Latex
  5. | Lcalc
  6. | Makefile
  7. | OCaml
  8. | Proof
  9. | Python
  10. | Scalc
  11. | Scopelang
  12. | Typecheck
val language : string option Cmdliner.Term.t
val max_prec_digits_opt : int option Cmdliner.Term.t
val ex_scope : string option Cmdliner.Term.t
val output : string option Cmdliner.Term.t
val catala_t : (string -> bool -> bool -> bool -> bool -> string -> string option -> int option -> bool -> bool -> bool -> string option -> string option -> 'a) -> 'a Cmdliner.Term.t

Main entry point: catala_t file debug unstyled wrap_weaved_output avoid_exceptions backend language max_prec_digits_opt trace_opt disable_counterexamples optimize ex_scope output

val version : string

Terminal formatting

Markers

val print_with_style : ANSITerminal.style list -> ('a, unit, string) format -> 'a
val format_with_style : ANSITerminal.style list -> Format.formatter -> string -> unit
val debug_marker : unit -> string
val error_marker : unit -> string
val warning_marker : unit -> string
val result_marker : unit -> string
val log_marker : unit -> string

Printers

All the printers below print their argument after the correct marker

val concat_with_line_depending_prefix_and_suffix : (int -> string) -> (int -> string) -> string list -> string
val add_prefix_to_each_line : string -> (int -> string) -> string

The int argument of the prefix corresponds to the line number, starting at 0

val debug_print : string -> unit
val error_print : string -> unit
val warning_print : string -> unit
val result_print : string -> unit
val log_print : string -> unit