package ocamlformat-lib

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
module Error : sig ... end
val parse_and_format : Syntax.t -> ?output_file:Ocamlformat_stdlib.string -> input_name:Ocamlformat_stdlib.string -> source:Ocamlformat_stdlib.string -> Conf.t -> (Ocamlformat_stdlib.string, Error.t) Ocamlformat_stdlib.Result.t

parse_and_format kind ?output_file ~input_name ~source conf opts parses and formats source as a list of fragments.

numeric ~input_name ~source ~range conf opts returns the indentation of the range of lines range (line numbers ranging from 1 to number of lines), where the line numbers are relative to source and the indentation is relative to the formatted output.

OCaml

Innovation. Community. Security.