ReductionBounds.PortSource (ReductionBounds v0.1.0)

Copy Markdown View Source

Reifies a finite, contracted Port-client fragment from BEAM debug information.

The target has two arguments: the Port and the preparation input. Supported blocks are a static preparation binding, a Boolean case on :erlang.port_command(port, request, [:nosuspend]), a static response-helper case with {:data, payload}, :closed, and :timeout patterns, and a static decoding call. Boolean and reply clauses may be reordered. All guards must be literal true; the compiler-generated case failure is retained as an excluded outcome under the declared call-result contracts.

Helper contracts are explicit assumptions, not inferred properties of their implementations. Native receive, recursion, dynamic calls, blocking command submission, exceptions and other unsupported syntax report the target and source path. Proof generation and checking are provided by the source proof builder. Source extraction and reification remain trusted boundaries.

Summary

Functions

infer(target, profile, options \\ [])

@spec infer(ReductionBounds.target(), ReductionBounds.ProtocolCost.t(), keyword()) ::
  {:ok, map()} | {:error, term()}