Closed radeusgd closed 4 years ago
Something like this can be achieved by calling eapply IHt1 in H
where H is one of the assumptions needed for IHt1.
For example:
Lemma sandbox : forall t T,
(forall t1 T, ∅ ⊢(L0) t1 ∈ T -> isvalue t1) ->
∅ ⊢(L0) t ∈ T ->
isvalue t \/ False.
intros.
remember H0 as H0' eqn:removeme; clear removeme.
eapply H in H0.
...
One can also use remember to keep the original hypothesis.
One can also use rewrite with hypotheses that are not directly an equality but in the full form forall ..., H1 -> ... -> Hn -> equality
.
It often happens (for example when doing induction), that I have a complex hypothesis with a forall quantifier, like
I have some T that I know will fit. Its conclusion is not directly applicable to my current goal, so I cannot do
apply IHt1 with SomeT
noreapply IHt2
.What I do is
I'm however wondering if it's possible to do that in a more concise way (like writing the
assert
without mentioning the full conclusion as it can be inferred from the IH.I' mostly thinking Don't Repeat Yourself principle - I have the conclusion already in IH so copy-pasting it into assert sounds risk (as if I change it slightly the assert will no longer work).