Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] Turning an evar into a goal?

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] Turning an evar into a goal?


Chronological Thread 
  • From: Jonathan Leivent <jonikelee AT gmail.com>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] Turning an evar into a goal?
  • Date: Sun, 2 Apr 2017 21:33:33 -0400
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=jonikelee AT gmail.com; spf=Pass smtp.mailfrom=jonikelee AT gmail.com; spf=None smtp.helo=postmaster AT mail-qt0-f178.google.com
  • Ironport-phdr: 9a23:GDFYMhRP1Jec5HDOwDZDHIqLR9psv+yvbD5Q0YIujvd0So/mwa69bRGN2/xhgRfzUJnB7Loc0qyN4vymATRIyK3CmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+KPjrFY7OlcS30P2594HObwlSijewZbx/IA+qoQnNq8IbnZZsJqEtxxXTv3BGYf5WxWRmJVKSmxbz+MK994N9/ipTpvws6ddOXb31cKokQ7NYCi8mM30u683wqRbDVwqP6WACXWgQjxFFHhLK7BD+Xpf2ryv6qu9w0zSUMMHqUbw5Xymp4KB3RRLmiioKOSc1/H3Yh8dtiK5WoA6tqxl5zoXJYo+aKeB+c7vAc90ES2pPXsVfWSJPDYyzbYQAE+UPMP1Er4T/vVYCsQeyCAeuCe7p1zRGhmX23ao/0+k5FQ/G2wogEMgSsHTUttr1MroZX+arw6nJ0zXMcfVW2Svg44XPcBAhpveMXbNzccXPzUkgCR3Kg06fqYzgJTyV1+ANv3KH4OpnUOKikmgqoBx/rDiow8cjkIjJhoQNx1DF8yV52oc1KseiRE51e96pFoZbuSKCN4ZuXM8uX2VltDw5x7AGo5K3YjUGxZU9yxLCafGKcJCE7gzsWeqLIDp0mWhpdbGxihqo8UWtzuvxXdSu3llQtCpKiNzMu2gN1xPN7siHTeNw/kK71jaO0wDf8/hEIVwomabCJZ4t37w9m5kJvUTMGS/2n0r2jKuIeUk+5ueo7OHnbq3npp+aKYB0lhnzProylsG7G+g1MQgDU3KF9eih1bDv51D1TbdJg/Eul6nWqpHaJcAVpq6jBA9V154u6xS4Dzeg0dQYnmcILFZbdx2ZlIXpNFTOL+r5Dfe7mVijjDBrx/XeMr37HprNNmTDkKvmfbtl90FczxMzwclD6JJQF7EOO+n+WlTxtdzdFh82KRa4w+fhCNVn14MRQ3iDAqGDMPCajVjd7eU2ZuKIeYU9uTDnKvFj6eS9o2U+nAo/eq+gwZsebjicE/V4LkOFKS7uhdEAEmoOswcWQ+njiVnEWjlWMSXhF5kg7y02Xdr1RbzIQZqg1eHZ0Q==



On 04/02/2017 08:29 PM, Jason Gross wrote:
I can't seem to get it to work, even if they are skolemized. Here's a toy
example that works, but when I do the same thing in my actual example,
[Defined] takes over 30 hours and over 10 GB of RAM after the refine:

Axioms A B : Prop.
Goal exists a : A, B.
clear; intros; evar (a:A); exists a.
(*
a := ?a : A
============================
B
*)
revert a.
refine (let pf : A /\ B := _ in (proj2 pf : let f' := proj1 pf in B)).
(*
============================
A /\ B
*)

Here are my failed attempts using the strategy I think you're proposing:
Axioms A B : Prop.
Goal exists a : A, B.
clear; intros; evar (a:A); exists a.
revert a.
instantiate (1:=ltac:(refine (proj1 ?[a']))).
simple refine (let pf : A /\ B := ?[pf] in _); cycle 1.
intro a.
Fail unify a (proj1 pf).
Fail unify (proj1 pf) a.
Fail all: [ > unify ?pf ?a' | ]; [ | ].
Fail all: [ > unify ?a' ?pf | ]; [ | ].


Do you have any ideas?

I think that's a bug in unify, maybe related to https://coq.inria.fr/bugs/show_bug.cgi?id=4957.

Try this:

Axioms A B : Prop.
Goal exists a : A, B.
clear; intros; evar (a:A); exists a.
revert a.
instantiate (1:=ltac:(refine (proj1 ?[a']))).
simple refine (let pf : A /\ B := ?[pf] in _); cycle 1.
intro a.
let unused := constr:(eq_refl:(a = proj1 pf)) in idtac.

-- Jonathan





Archive powered by MHonArc 2.6.18.

Top of Page