Somehow in my assumptions I had something that looks like this:
filtered_var:= l : list A
I need to somehow convert to something that looks like:
H: filter_var = l
so I can use it with normal tactics as subst. The problem is that some places I see filtered_var
used while in other places I see l
used and I cannot get coq to replace with one term.
filtered_var
is a local definition, so unfold filtered_var
will replace it by its body l
; you can also do simpl
before intros
, as in the snippet I posted recently
(in https://coq.zulipchat.com/#narrow/stream/237977-Coq-users/topic/Dependent.20vectors)
oh I see, I always had the pattern of intros;subst;simpl in *.
but thanks for the unfold trick!
never noticed that order matters
easy part: simpl only acts on the conclusion, otherwise you want simpl in * to do each hypothesis.
Sorry, not easy, but it comes up often
It's less common to have let in goals, so these subtleties come up less often
lazy zeta
can also be more focused on just unfolding lets than simpl
.
Last updated: Oct 05 2023 at 02:01 UTC