Module Patdiff_kernel.Configuration

val default_context : int

Default amount of context shown around each change in the diff

The following constants were all chosen empirically.

val default_line_big_enough : int

Default cutoff for line-level semantic cleanup. Any match of default_line_big_enough or more will not be deleted, even if it's surrounded by large inserts and deletes. Raising this quantity can only decrease the number of matches, and lowering it can only increase the number of matches.

val default_word_big_enough : int

Analogous to default_line_big_enough, but for word-level refinement

val too_short_to_split : int

Governs the behavior of split_for_readability. We will only split ranges around matches of size greater than too_short_to_split. Note that this should always be at least 1, otherwise we will split on a single `Newline token. Raising this quantity will result in less ranges being split, and setting it to infinity is the same as passing in ~interleave:false.

val warn_if_no_trailing_newline_in_both_default : bool
type t = private {
  1. output : Output.t;
  2. rules : Format.Rules.t;
  3. float_tolerance : Core.Percent.t option;
  4. produce_unified_lines : bool;
  5. unrefined : bool;
  6. keep_ws : bool;
  7. find_moves : bool;
  8. split_long_lines : bool;
  9. interleave : bool;
  10. assume_text : bool;
  11. context : int;
  12. line_big_enough : int;
  13. word_big_enough : int;
  14. shallow : bool;
  15. quiet : bool;
  16. double_check : bool;
  17. mask_uniques : bool;
  18. prev_alt : string option;
  19. next_alt : string option;
  20. location_style : Format.Location_style.t;
  21. warn_if_no_trailing_newline_in_both : bool;
  22. side_by_side : [ `wrap | `truncate ] option;
  23. width_override : int option;
}
include Ppx_compare_lib.Comparable.S with type t := t
val compare : t -> t -> int
include Ppx_compare_lib.Comparable.S__local with type t := t
val width_override : t -> int option @@ portable
val side_by_side : t -> [ `wrap | `truncate ] option @@ portable
val warn_if_no_trailing_newline_in_both : t -> bool @@ portable
val location_style : t -> Format.Location_style.t @@ portable
val next_alt : t -> string option @@ portable
val prev_alt : t -> string option @@ portable
val mask_uniques : t -> bool @@ portable
val double_check : t -> bool @@ portable
val quiet : t -> bool @@ portable
val shallow : t -> bool @@ portable
val word_big_enough : t -> int @@ portable
val line_big_enough : t -> int @@ portable
val context : t -> int @@ portable
val assume_text : t -> bool @@ portable
val interleave : t -> bool @@ portable
val split_long_lines : t -> bool @@ portable
val find_moves : t -> bool @@ portable
val keep_ws : t -> bool @@ portable
val unrefined : t -> bool @@ portable
val produce_unified_lines : t -> bool @@ portable
val float_tolerance : t -> Core.Percent.t option @@ portable
val rules : t -> Format.Rules.t @@ portable
val output : t -> Output.t @@ portable
val sexp_of_t : t -> Sexplib0.Sexp.t
include Core.Invariant.S with type t := t
val invariant : t -> unit
val create_exn : output:Output.t -> rules:Format.Rules.t -> float_tolerance:Core.Percent.t option -> produce_unified_lines:bool -> unrefined:bool -> keep_ws:bool -> find_moves:bool -> split_long_lines:bool -> interleave:bool -> assume_text:bool -> context:int -> line_big_enough:int -> word_big_enough:int -> shallow:bool -> quiet:bool -> double_check:bool -> mask_uniques:bool -> prev_alt:string option -> next_alt:string option -> location_style:Format.Location_style.t -> warn_if_no_trailing_newline_in_both:bool -> side_by_side:[ `wrap | `truncate ] option -> width_override:int option -> t

Raises if invariant t fails.

val override : ?output:Output.t -> ?rules:Format.Rules.t -> ?float_tolerance:Core.Percent.t option -> ?produce_unified_lines:bool -> ?unrefined:bool -> ?keep_ws:bool -> ?find_moves:bool -> ?split_long_lines:bool -> ?interleave:bool -> ?assume_text:bool -> ?context:int -> ?line_big_enough:int -> ?word_big_enough:int -> ?shallow:bool -> ?quiet:bool -> ?double_check:bool -> ?mask_uniques:bool -> ?prev_alt:string option -> ?next_alt:string option -> ?location_style:Format.Location_style.t -> ?warn_if_no_trailing_newline_in_both:bool -> ?side_by_side:[ `wrap | `truncate ] option -> ?width_override:int option -> t -> t
val default : t