-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add lemma length_app_comm #75
add lemma length_app_comm #75
Conversation
Not sure why the CI fails but will look into it. |
Coq-Elpi error is:
Very unclear for Rewriter (idem for Fiat-crypto-legacy). Equations-test error looks like a GitHub Action issue (unclear what happened from the log). Idem for Metacoq-template-coq. @proux01 Any idea what is going on here? Should we just relaunch the failed jobs? |
Elpi is known to be currently broken. Fiat-crypto and rewriter might be actual overlays needed, not sure for the others. |
@NicholasBHubbard CI in other PR confirms that coq-elpi is unrelated but you need to investigate more the other CI failures. |
The failures still happen and this time, I identified the cause of at least one of them:
Now, my guess is that this comes from having adding this lemma to a rewrite hint database. Probably this creates an infinite loop and that's also the reason why these jobs take such a long time to fail. |
Looks like removing the lemma from the rewrite hint database fixed it |
d1933c9
to
a71c168
Compare
Rebased to relaunch CI now that it's fixed, just to be on the safe side. |
Thanks to both of you for the contrib and the debuging |
This PR adds to List.v a lemma:
Lemma length_app_comm : forall l l' : list A, length (l++l') = length (l'++l).
I'd like to preface by saying that I am new to Coq so may be ignorant of many things. However, I was in need of such a lemma in one of my proofs and was surprised that an obvious fact such as this did not already exist in the stdlib. I hope that
length_app_comm
is a good name for this. I read over coq/coq#18564 where the naming convention of these lemmas was discussed, and I believe that I followed it correctly.One thing I am unsure about is if I was correct to add the new lemma under the
Global Hint Rewrite
here:Was this the correct thing to do?
Please let me know if you believe
length_app_comm
would be a good addition to List.v, and if anything else needs to be done. Thanks!