View Source Bond.PostconditionError exception (Bond v1.2.1)

Exception raised when a function postcondition fails.

Summary

Types

t()

The Bond.PostconditionError exception type.

Types

@type t() :: %Bond.PostconditionError{
  __exception__: term(),
  binding: keyword(),
  expression: Bond.assertion_expression(),
  file: Path.t(),
  function: {String.t(), non_neg_integer()},
  impl: module() | nil,
  label: Bond.assertion_label(),
  line: integer(),
  module: module(),
  source_behaviour: module() | nil,
  source_protocol: module() | nil
}

The Bond.PostconditionError exception type.

:source_behaviour is the behaviour module an inherited contract came from (see Bond.Behaviour), or nil for a contract declared directly on the function.

:source_protocol is the protocol module a contract was declared on (see Bond.Protocol), or nil; when set, :impl is the implementation module the failing call resolved to (or nil if none could be resolved).