TorchLean API

FloatLib.Floats.Formats.Posit.Configured.Real

Optional real-valued views of configured posits #

This adapter embeds the exact rational value of an ordinary configured posit into mathlib's Real. The optional view returns none for NaR; the complete view retains its exceptional status.

@[inline]

Complete real-valued view of the exact rational semantics.

Instances For
    @[inline]
    noncomputable def FloatLib.Floats.ExecFloat.Posit.toReal? {format : Formats.Posit.Format} {plan : Formats.Posit.Configured.StoragePlan format} {code : Type} [codec : ModelCodec plan (Formats.Posit.Model format) code] (value : ExecFloat (Formats.Posit.Configured.Family format code plan)) :

    Exact real value of an ordinary configured posit, or none exactly for NaR.

    Instances For
      @[simp]

      The public optional real view is absent precisely for the unique NaR value.