\begin{lemma}[Scientific exponent bounds and boundary suffixes]
Every normal \texttt{Some} return of the extracted
\texttt{parse\_scientific} has value between $-655359$ and $655359$.
Moreover, the unsigned suffix \texttt{655360} returns $65536$ with no
unconsumed byte, and the signed suffix \texttt{-655359} returns $-655359$
with no unconsumed byte.
\end{lemma}
\begin{proof}
Unfold the extracted scientific parser in
\noderef{num_imp_dec2flt_parse_parse_scientific}.  After removing an optional
sign, its digit loop has the following invariant: the count is the number of
consumed digit bytes, the count is at most the slice length, and the
nonnegative accumulator is at most $655359$.  Initially both count and
accumulator are zero.  If the old accumulator $a$ is below $65536$, a digit
$d\in\{0,\ldots,9\}$ changes it by the checked operations
$a\mapsto10a+d$.  Hence the new value is at most
$10\cdot65535+9=655359$, well inside the signed 64-bit range.  If
$a\geq65536$, the guard leaves it unchanged.  The byte access is justified by
the loop test \texttt{count < len}; the following checked count increment is
safe because its result is at most the slice length and hence at most
\texttt{Usize.max}.  The final slice starts at that same in-bounds count.
Thus every unsigned result is in $[0,655359]$.  The only remaining operation
for a leading minus is checked negation; negating this interval is safe and
gives the asserted two-sided bound.

For bytes \texttt{655360}, successive accumulator values after the first five
digits are
\[
  0,\ 6,\ 65,\ 655,\ 6553,\ 65536.
\]
The sixth iteration reads the final zero in bounds, but its old accumulator is
already $65536$, so the strict guard is false and the value stays $65536$.
The count then equals six, the loop terminates, and slicing at six leaves the
empty slice.  There is no sign to negate.

For bytes \texttt{-655359}, the leading minus is removed before the loop.
The six digit iterations have values
\[
  0,\ 6,\ 65,\ 655,\ 6553,\ 65535,\ 655359.
\]
Here the old value before the last digit is $65535<65536$, so the checked
multiplication and addition are taken.  Count six again leaves an empty
slice, and the final safe negation returns $-655359$.  These calculations also
discharge every digit cast, multiplication, addition, index, increment, and
final slice bound in the two concrete evaluations.
\end{proof}
