Module Pulselib.PulseAccessResult

module AbductiveDomain = PulseAbductiveDomain
module DecompilerExpr = PulseDecompilerExpr
module Diagnostic = PulseDiagnostic
type error =
  1. | PotentialInvalidAccess of {
    1. astate : AbductiveDomain.t;
    2. address : DecompilerExpr.t;
    3. must_be_valid : Pulselib.PulseBasicInterface.Trace.t * Pulselib.PulseBasicInterface.Invalidation.must_be_valid_reason option;
    }
  2. | ReportableError of {
    1. astate : AbductiveDomain.t;
    2. diagnostic : Diagnostic.t;
    }
  3. | WithSummary of error * AbductiveDomain.Summary.t
    (*

    An error for which the summary corresponding to the abstract state has already been computed, to avoid having to compute the summary for a given abstract state multiple times. For convenience this is part of the error datatype but the invariant that an error within a WithSummary (error, summary) cannot itself be a WithSummary _.

    *)
val astate_of_error : error -> AbductiveDomain.t
type 'a t = ('a, error) PulseResult.t
val with_summary : ('a, error * AbductiveDomain.Summary.t) PulseResult.t -> 'a t

Intermediate datatype since AbductiveDomain cannot refer to this module without creating a circular dependency.

Purposefully omits `MemoryLeak errors as it's a good idea to double-check if you really want to report a leak.

val of_result_f : ('a, error) IStdlib.IStd.result -> f:(error -> 'a) -> 'a t
val of_error_f : error -> f:(error -> 'a) -> 'a t
val of_abductive_summary_error : [< abductive_summary_error ] -> error * AbductiveDomain.Summary.t
val of_abductive_result : ('a, [< abductive_error ]) IStdlib.IStd.result -> 'a t
val of_abductive_summary_result : ('a, [< abductive_summary_error ]) IStdlib.IStd.result -> ('a, error * AbductiveDomain.Summary.t) PulseResult.t