\begin{lemma}[Slow-guard control-flow certificate]
Suppose the traced dispatcher is invoked on a source-valid string $s$, returns
successfully with an assembled record $t$, its slow-path guard is true, and
parsing $t.\mathit{body}$ returns the numeric record $r$.  Suppose also that a
true \texttt{many\_digits} field implies $r.\mathit{mantissa}>0$.  Then
\[
             -342\le r.\mathit{exponent}\le308,
\]
and there is a decimal sequence $d$ such that
\texttt{parse\_decimal\_seq($t.body$)=ok $d$} and
\texttt{parse\_long\_mantissa($t.body$)=ok $t.selected\_pair$} for the
concrete binary64 trait instance.
\end{lemma}
\begin{proof}
Unfold \noderef{num_imp_dec2flt_dec2flt_with_trace} along the assumed normal
return.  Every failed bind would propagate a failed \texttt{Result}, so all
binds on this execution return normally.  The supplied parse equation and
determinism of the extracted function identify its record with the record
used by the dispatcher.  The assembled constructor rules out the native
fast-result arm.  Hence the first integer call is exactly
\[
 \texttt{compute\_float}(r.\mathit{exponent},r.\mathit{mantissa}).
\]

We prove the exponent bounds by contradiction.  By
\noderef{ParserExponentConstants}, the concrete smallest and largest decimal
powers read by \noderef{num_imp_dec2flt_lemire_compute_float} are $-342$ and
$308$, and its infinite biased exponent is 2047.  Unfolding
\noderef{num_imp_dec2flt_common_BiasedFp_zero_pow2} at biased exponents zero
and 2047 gives exactly the fixed zero and infinity pairs, each with mantissa
zero and with its stated biased exponent.  If the mantissa is zero, the first
branch of the compute definition returns the fixed zero pair.  If the mantissa is nonzero and
$r.\mathit{exponent}<-342$, the next cutoff branch returns that same zero
pair.  If the mantissa is nonzero and
$r.\mathit{exponent}>308$, the upper cutoff branch returns the fixed infinity
pair, whose biased exponent is 2047.  Thus outside the closed interval the
first pair always has nonnegative biased exponent.

If \texttt{many\_digits} is false, the dispatcher does not make an adjacent
call and uses this fixed pair directly.  If it is true, nonnegativity enables
the adjacent call with mantissa plus one.  Normal return of the surrounding
dispatcher discharges the checked increment.  The added premise makes the
original mantissa nonzero in this branch, and its successor is nonzero as
well.  For the same out-of-range exponent, both compute calls therefore
reach the same exponent cutoff and return the same fixed zero or infinity
pair.  Unfolding
\noderef{num_imp_dec2flt_common_BiasedFp_Insts_CoreCmpPartialEqBiasedFp_eq}
at either identical concrete pair makes the mantissa comparison true and then
the biased-exponent comparison true.  The extracted adjacent-pair equality
test is therefore true, so the
post-comparison pair is again that fixed pair rather than the forced
$-1$-exponent sentinel.  In both many and non-many cases its biased exponent
is nonnegative.  The following test
\texttt{post\_comparison\_pair.p\_biased < 0} is false, forcing
\texttt{slow\_path\_guard=false}.  This contradicts the hypothesis.  Hence
$-342\le r.\mathit{exponent}\le308$.

With the slow guard true, that same final comparison took its negative arm.
The branch makes exactly one call to
\noderef{num_imp_dec2flt_slow_parse_long_mantissa} on $t.\mathit{body}$ and
assigns its returned pair simultaneously to \texttt{selected\_pair} and to
\texttt{some slow\_path\_result}.  Constructor injectivity for the assumed
assembled trace therefore gives
\[
 \texttt{parse\_long\_mantissa($t.body$)=ok $t.selected\_pair$}. \tag{1}
\]

Finally unfold the slow function in (1).  After constructing the fixed zero
and infinity pairs, its first input-dependent bind is precisely
\noderef{num_imp_dec2flt_decimal_seq_parse_decimal_seq} on the same body.
If this bind failed, the slow call could not equal the normal result in (1).
Thus it returns \texttt{ok $d$} for some sequence $d$.  Choosing that $d$,
together with (1) and the already proved exponent bounds, gives every
conjunct and the existential conclusion.
\end{proof}
