src/CTT/bool.thy
author wenzelm
Wed, 09 Jul 1997 17:00:34 +0200
changeset 3511 da4dd8b7ced4
parent 0 a5a9c433f639
permissions -rw-r--r--
removed obsolete init_pps and init_thy_reader;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     1
(*  Title: 	CTT/bool
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     2
    ID:         $Id$
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     3
    Author: 	Lawrence C Paulson, Cambridge University Computer Laboratory
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     4
    Copyright   1991  University of Cambridge
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     5
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     6
The two-element type (booleans and conditionals)
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     7
*)
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     8
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     9
Bool = CTT +
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    10
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    11
consts Bool		:: "t"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    12
       true,false	:: "i"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    13
       cond		:: "[i,i,i]=>i"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    14
rules
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    15
  Bool_def	"Bool == T+T"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    16
  true_def	"true == inl(tt)"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    17
  false_def	"false == inr(tt)"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    18
  cond_def	"cond(a,b,c) == when(a, %u.b, %u.c)"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    19
end