From 8881e203658bb17d37bdea24ea3e104d0466e2e8 Mon Sep 17 00:00:00 2001 From: Stefano Zacchiroli Date: Mon, 7 Nov 2005 10:04:22 +0000 Subject: [PATCH] added bool_elim (elimination which preserves infos on the eliminated value) --- helm/matita/library/datatypes/bool.ma | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/helm/matita/library/datatypes/bool.ma b/helm/matita/library/datatypes/bool.ma index a4667da30..11f1d7a8c 100644 --- a/helm/matita/library/datatypes/bool.ma +++ b/helm/matita/library/datatypes/bool.ma @@ -19,7 +19,18 @@ include "logic/equality.ma". inductive bool : Set \def | true : bool | false : bool. - + +theorem bool_elim: \forall P:bool \to Prop. \forall b:bool. + (b = true \to P true) + \to (b = false \to P false) + \to P b. + intros 2 (P b). + elim b; + [ apply H; reflexivity + | apply H1; reflexivity + ] +qed. + theorem not_eq_true_false : true \neq false. simplify.intro. change with -- 2.39.2