| 1 |
Require Import Ltac2.Ltac2. |
| 2 |
|
| 3 |
Import Ltac2.Notations. |
| 4 |
|
| 5 |
Goal True. |
| 6 |
Proof. |
| 7 |
Fail fail. |
| 8 |
Fail solve [ () ]. |
| 9 |
try fail. |
| 10 |
repeat fail. |
| 11 |
repeat (). |
| 12 |
solve [ constructor ]. |
| 13 |
Qed. |
| 14 |
|
| 15 |
Goal True. |
| 16 |
Proof. |
| 17 |
first [ |
| 18 |
Message.print (Message.of_string "Yay"); fail |
| 19 |
| constructor |
| 20 |
| Message.print (Message.of_string "I won't be printed") |
| 21 |
]. |
| 22 |
Qed. |
| 23 |
|
| 24 |
Goal True /\ True. |
| 25 |
Proof. |
| 26 |
Fail split > [ split | |]. |
| 27 |
split > [split | split]. |
| 28 |
Qed. |
| 29 |
|
| 30 |
Goal True /\ (True -> True) /\ True. |
| 31 |
Proof. |
| 32 |
split > [ | split] > [split | .. | split]. |
| 33 |
intros H; refine &H. |
| 34 |
Qed. |