Ocamlformat_lib.Source
val create :
text:Ocamlformat_stdlib.string ->
tokens:
(Parser_extended.Parser.token * Ocaml_common.Location.t)
Ocamlformat_stdlib.list ->
t
val empty_line_between :
t ->
Lexing.position ->
Lexing.position ->
Ocamlformat_stdlib.bool
val empty_line_before : t -> Ocaml_common.Location.t -> Ocamlformat_stdlib.bool
val empty_line_after : t -> Ocaml_common.Location.t -> Ocamlformat_stdlib.bool
val tokens_between :
t ->
filter:(Parser_extended.Parser.token -> Ocamlformat_stdlib.bool) ->
Lexing.position ->
Lexing.position ->
(Parser_extended.Parser.token * Ocaml_common.Location.t)
Ocamlformat_stdlib.list
val string_at : t -> Ocaml_common.Location.t -> Ocamlformat_stdlib.string
val find_token_after :
t ->
filter:(Parser_extended.Parser.token -> Ocamlformat_stdlib.bool) ->
Lexing.position ->
(Parser_extended.Parser.token * Ocaml_common.Location.t)
Ocamlformat_stdlib.option
val find_token_before :
t ->
filter:(Parser_extended.Parser.token -> Ocamlformat_stdlib.bool) ->
Lexing.position ->
(Parser_extended.Parser.token * Ocaml_common.Location.t)
Ocamlformat_stdlib.option
val string_literal :
t ->
[ `Normalize | `Preserve ] ->
Ocaml_common.Location.t ->
Ocamlformat_stdlib.string
val begins_line :
?ignore_spaces:Ocamlformat_stdlib.bool ->
t ->
Ocaml_common.Location.t ->
Ocamlformat_stdlib.bool
val ends_line : t -> Ocaml_common.Location.t -> Ocamlformat_stdlib.bool
val extension_using_sugar :
name:Ocamlformat_stdlib.string Ocaml_common.Location.loc ->
payload:Ocaml_common.Location.t ->
Ocamlformat_stdlib.bool
val extend_loc_to_include_attributes :
Ocaml_common.Location.t ->
Ocamlformat_lib.Extended_ast.attributes ->
Ocaml_common.Location.t
val type_constraint_is_first :
Ocamlformat_lib.Extended_ast.core_type ->
Ocaml_common.Location.t ->
Ocamlformat_stdlib.bool
val is_quoted_string : t -> Ocaml_common.Location.t -> Ocamlformat_stdlib.bool
val loc_of_first_token_at :
t ->
Ocaml_common.Location.t ->
Parser_extended.Parser.token ->
Ocaml_common.Location.t Ocamlformat_stdlib.option
val find_first_token_on_line :
t ->
Ocamlformat_stdlib.int ->
(Parser_extended.Parser.token * Ocaml_common.Location.t)
Ocamlformat_stdlib.option