Skip to content

Instantly share code, notes, and snippets.

@Blaisorblade
Created April 5, 2023 11:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Blaisorblade/4bdf85e6dbf7e5d7096da93409b1911e to your computer and use it in GitHub Desktop.
Save Blaisorblade/4bdf85e6dbf7e5d7096da93409b1911e to your computer and use it in GitHub Desktop.
Automation over coq-iris's IPM/MoSeL: Demonstrate how to generate patterns programmatically for proof automation
Require Import iris.proofmode.proofmode.
Require Import iris.proofmode.intro_patterns.
Section foo.
Context {PROP : bi}.
Context (P R : PROP) (lem : P ⊢ P ∗ R).
Goal True. let x := intro_pat.parse "[A B]" in idtac x. Abort.
(* output: *)
(* [IList [[IIdent "A"; IIdent "B"]]]. *)
Goal P ⊢ False.
iIntros "P".
iSelect P%I (fun name =>
let x := iFresh in
let p := constr:(IList [[IIdent name; IIdent x]]) in
iDestruct (lem with name) as p).
Abort.
End foo.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment