Skip to content
Snippets Groups Projects
Commit 723ad25f authored by Robbert Krebbers's avatar Robbert Krebbers
Browse files

Add test for `destruct select`.

parent a1272450
No related branches found
No related tags found
No related merge requests found
...@@ -55,6 +55,17 @@ Proof. intros ?. rename select nat into m. exists m. done. Qed. ...@@ -55,6 +55,17 @@ Proof. intros ?. rename select nat into m. exists m. done. Qed.
Goal (P : nat Prop), P 3 P 4 P 4. Goal (P : nat Prop), P 3 P 4 P 4.
Proof. intros P **. rename select (P _) into HP4. apply HP4. Qed. Proof. intros P **. rename select (P _) into HP4. apply HP4. Qed.
Goal P Q : Prop, True True P Q Q P.
Proof.
intros P Q ??. (* should select the last hypothesis *)
destruct select (_ _); by constructor.
Restart.
intros P Q ??. (* should select the last hypothesis *)
destruct select (_ _) as [H1|H2].
- right. exact H1.
- left. exact H2.
Qed.
(** Regression tests for [naive_solver]. *) (** Regression tests for [naive_solver]. *)
Lemma naive_solver_issue_115 (P : nat Prop) (x : nat) : Lemma naive_solver_issue_115 (P : nat Prop) (x : nat) :
( x', P x' x' = 10) P x x + 1 = 11. ( x', P x' x' = 10) P x x + 1 = 11.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment