extracting evidence of equality from match
问题 I am trying to make the following work: Definition gen `{A:Type} {i o: nat} (f: nat -> (option nat)) {ibound: forall (n n':nat), f n = Some n' -> n' < i} (x: svector A i) (t:nat) (ti: t < o): option A := match (f t) with | None => None | Some t' => Vnth x (ibound t t' _) end. In place of last "_" I need an evidence that "f t" is equals to "Some t'". I could not figure out how to get it from the match. Vnth is defined as: Vnth : ∀ (A : Type) (n : nat), vector A n → ∀ i : nat, i < n → A 回答1: