Machete.Mismatch (Machete v0.3.11)

View Source

Data and functions to deal with representing mismatches

Summary

Types

t()

Describes the details of a mismatch

Functions

Pretty prints the specified list of mismatches, in a manner suitable for presentation to the user

Constructs an instance of Matchable.Mismatch with the given message and path, wrapped in a list and suitable for return from a Machete.Matchable.mismatches/2 call

Helper that inspects the given term ensuring map ordering

Types

t()

@type t() :: %Machete.Mismatch{message: String.t(), path: [term()]}

Describes the details of a mismatch

Functions

format_mismatches(mismatches, indent \\ "")

Pretty prints the specified list of mismatches, in a manner suitable for presentation to the user

mismatch(message, path \\ nil)

Constructs an instance of Matchable.Mismatch with the given message and path, wrapped in a list and suitable for return from a Machete.Matchable.mismatches/2 call

safe_inspect(term)

Helper that inspects the given term ensuring map ordering