Add lemmas `app_cons_eq_inv_{l,r}`.
This MR contains two commits: One with the actual lemmas, and one to perform some rearrangements. To prove the _r
variant, I needed properties of reverse
. I thus moved the reverse
lemmas above the elem_of
lemmas.
The lemmas in this MR generalize the ones in !356 (merged). They also allow proving a variant for suffix_of
, which is missing in that MR.
/cc @jihgfee
Merge request reports
Activity
mentioned in merge request !356 (merged)
These lemmas seem useful. As discussed elsewhere, a direct consequence of their conclusion is that
x = y
andl2 = k2
(for the prefix variant). Even though these are immediate (from something likesimplify_eq
), I think it is nicer to add them. Especially since the referenced variants would instead havex = y
andl2 prefix_of k2
, which is not as trivial.Thank you @jihgfee. I have added all the equalities as additional conclusions.
mentioned in commit f71300ea