| 1 |
Inductive type : Set := |
| 2 |
Tptr : type -> type |
| 3 |
| Tref : type -> type |
| 4 |
| Trv_ref : type -> type |
| 5 |
| Tint : type -> type -> type |
| 6 |
| Tvoid : type |
| 7 |
| Tarray : type -> type -> type |
| 8 |
| Tnamed : type -> type |
| 9 |
| Tfunction : type -> type -> type -> type |
| 10 |
| Tbool : type |
| 11 |
| Tmember_pointer : type -> type -> type |
| 12 |
| Tfloat : type -> type |
| 13 |
| Tqualified : type -> type -> type |
| 14 |
| Tnullptr : type |
| 15 |
| Tarch : type -> type -> type |
| 16 |
. |
| 17 |
Definition type_eq_dec : forall (ty1 ty2 : type), { ty1 = ty2 } + { ty1 <> ty2 }. |
| 18 |
Proof. fix IHty1 1. decide equality. Defined. |
| 19 |
|
| 20 |
Goal (if type_eq_dec (Tptr Tvoid) (Tptr Tvoid) then True else False). |
| 21 |
Proof. |
| 22 |
timeout 1 cbn. |
| 23 |
constructor. |
| 24 |
Qed. |