proposition: Lemma substring_length_no_min {offset len s} (Hshort : len = 0 \/ offset + len <= length s) : length (substring offset len s) = len.
proof: Proof. rewrite substring_length; destruct Hshort as [Hshort|Hshort]; try rewrite Nat.min_r by (clear -Hshort; omega); subst; simpl; rewrite <- ?Nat.sub_min_distr_r, ?Nat.add_sub, ?Nat.sub_diag, ?Nat.min_0_r; reflexivity. Qed.
imports: Fiat.Common.Coq__8_4__8_5__Compat Coq.ZArith.ZArith Fiat.Common Fiat.Common.List.Operations Fiat.Common.List.ListFacts Fiat.Common.Le Fiat.Common.Tactics.SetoidSubst Fiat.Common.Tactics.IsClosed Fiat.Parsers.StringLike.Core Fiat.Common.UIP