\begin{helper}[Final zero fill preserves the digit prefix]
For any 768-cell digit array $a$ and Usize start index $r$, the first final
zero-fill loop of the extracted decimal-sequence parser returns normally with
an array $a'$, and
\[
  \operatorname{take}(r,a')=\operatorname{take}(r,a).
\]
The other three final-fill loops have the same extracted body and hence the
same property by definitional equality.
\end{helper}
\begin{proof}
The loop and its range iterator are those in
\noderef{num_imp_dec2flt_decimal_seq_parse_decimal_seq}; its fixed end is 19
by the extracted constant
\noderef{num_imp_dec2flt_decimal_seq_DecimalSeq_MAX_DIGITS_WITHOUT_OVERFLOW}.
Maintain that the iterator's current start is at least $r$, its end is 19,
and the current array's first $r$ cells equal those of $a$.  Use the remaining
range length as the decreasing measure.

If current start is not below 19, the iterator returns no element and the
array is returned with the invariant unchanged.  Otherwise the current index
$i$ satisfies $r\le i<19<768$.  Its checked successor is representable on the
configured 64-bit Usize model, and the array update at $i$ is in bounds.
The list law for updating at an index at least $r$ shows that taking the first
$r$ cells is unchanged.  The iterator start becomes $i+1$, still at least
$r$, while the natural-number distance to 19 decreases strictly.  Well-founded
loop induction therefore proves normal return and prefix preservation.  The
model definitions of loops 4, 6, and 7 are byte-for-byte the same functional
body as loop 1, so Lean reduces each of them to this proved loop when used by
the shared parser theorem.
\end{proof}
