package ocamlformat-lib

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Ocamlformat_lib.CmtSource

Sourcetype t
Sourceval is_docstring : t -> Ocamlformat_stdlib.bool
include Ocamlformat_stdlib.Comparator.S with type t := t
type comparator_witness
val comparator : (t, comparator_witness) Base__Comparator.comparator
Sourcetype error = {
  1. kind : [ `Added of t | `Modified of t * t | `Dropped of t ];
  2. cmt_kind : [ `Comment | `Doc_comment ];
}
Sourcetype pos =
  1. | Before
  2. | Within
  3. | After
Sourcetype decoded_kind =
  1. | Verbatim of Ocamlformat_stdlib.string
    (*

    Original content.

    *)
  2. | Doc of Ocamlformat_stdlib.string
    (*

    Original content.

    *)
  3. | Normal of Ocamlformat_stdlib.string
    (*

    Original content with indentation trimmed. Trailing spaces are not removed.

    *)
  4. | Code of Ocamlformat_stdlib.string
    (*

    Source code with indentation removed.

    *)
  5. | Asterisk_prefixed of Ocamlformat_stdlib.string Ocamlformat_stdlib.list
    (*

    Line splitted with asterisks removed.

    *)
Sourcetype decoded = {
  1. prefix : Ocamlformat_stdlib.string;
    (*

    Just after the opening.

    *)
  2. suffix : Ocamlformat_stdlib.string;
    (*

    Just before the closing.

    *)
  3. kind : decoded_kind;
}
Sourceval decode : parse_comments_as_doc:Ocamlformat_stdlib.bool -> t -> decoded
OCaml

Innovation. Community. Security.