src/HOL/Decision_Procs/Parametric_Ferrante_Rackoff.thy
changeset 38549 d0385f2764d8
parent 38136 bd4965bb7bdc
child 38558 32ad17fe2b9c
     1.1 --- a/src/HOL/Decision_Procs/Parametric_Ferrante_Rackoff.thy	Thu Aug 19 10:27:12 2010 +0200
     1.2 +++ b/src/HOL/Decision_Procs/Parametric_Ferrante_Rackoff.thy	Thu Aug 19 11:02:14 2010 +0200
     1.3 @@ -2960,7 +2960,7 @@
     1.4  val ifft = @{term "op = :: bool => _"}
     1.5  fun llt rT = Const(@{const_name Orderings.less},rrT rT);
     1.6  fun lle rT = Const(@{const_name Orderings.less},rrT rT);
     1.7 -fun eqt rT = Const("op =",rrT rT);
     1.8 +fun eqt rT = Const(@{const_name "op ="},rrT rT);
     1.9  fun rz rT = Const(@{const_name Groups.zero},rT);
    1.10  
    1.11  fun dest_nat t = case t of
    1.12 @@ -3015,26 +3015,26 @@
    1.13  
    1.14  fun fm_of_term m m' fm = 
    1.15   case fm of
    1.16 -    Const("True",_) => @{code T}
    1.17 -  | Const("False",_) => @{code F}
    1.18 -  | Const("Not",_)$p => @{code NOT} (fm_of_term m m' p)
    1.19 -  | Const("op &",_)$p$q => @{code And} (fm_of_term m m' p, fm_of_term m m' q)
    1.20 -  | Const("op |",_)$p$q => @{code Or} (fm_of_term m m' p, fm_of_term m m' q)
    1.21 -  | Const("op -->",_)$p$q => @{code Imp} (fm_of_term m m' p, fm_of_term m m' q)
    1.22 -  | Const("op =",ty)$p$q => 
    1.23 +    Const(@{const_name "True"},_) => @{code T}
    1.24 +  | Const(@{const_name "False"},_) => @{code F}
    1.25 +  | Const(@{const_name "Not"},_)$p => @{code NOT} (fm_of_term m m' p)
    1.26 +  | Const(@{const_name "op &"},_)$p$q => @{code And} (fm_of_term m m' p, fm_of_term m m' q)
    1.27 +  | Const(@{const_name "op |"},_)$p$q => @{code Or} (fm_of_term m m' p, fm_of_term m m' q)
    1.28 +  | Const(@{const_name "op -->"},_)$p$q => @{code Imp} (fm_of_term m m' p, fm_of_term m m' q)
    1.29 +  | Const(@{const_name "op ="},ty)$p$q => 
    1.30         if domain_type ty = bT then @{code Iff} (fm_of_term m m' p, fm_of_term m m' q)
    1.31         else @{code Eq} (@{code Sub} (tm_of_term m m' p, tm_of_term m m' q))
    1.32    | Const(@{const_name Orderings.less},_)$p$q => 
    1.33          @{code Lt} (@{code Sub} (tm_of_term m m' p, tm_of_term m m' q))
    1.34    | Const(@{const_name Orderings.less_eq},_)$p$q => 
    1.35          @{code Le} (@{code Sub} (tm_of_term m m' p, tm_of_term m m' q))
    1.36 -  | Const("Ex",_)$Abs(xn,xT,p) => 
    1.37 +  | Const(@{const_name "Ex"},_)$Abs(xn,xT,p) => 
    1.38       let val (xn', p') =  variant_abs (xn,xT,p)
    1.39           val x = Free(xn',xT)
    1.40           fun incr i = i + 1
    1.41           val m0 = (x,0):: (map (apsnd incr) m)
    1.42        in @{code E} (fm_of_term m0 m' p') end
    1.43 -  | Const("All",_)$Abs(xn,xT,p) => 
    1.44 +  | Const(@{const_name "All"},_)$Abs(xn,xT,p) => 
    1.45       let val (xn', p') =  variant_abs (xn,xT,p)
    1.46           val x = Free(xn',xT)
    1.47           fun incr i = i + 1
    1.48 @@ -3045,8 +3045,8 @@
    1.49  
    1.50  fun term_of_fm T m m' t = 
    1.51    case t of
    1.52 -    @{code T} => Const("True",bT)
    1.53 -  | @{code F} => Const("False",bT)
    1.54 +    @{code T} => Const(@{const_name "True"},bT)
    1.55 +  | @{code F} => Const(@{const_name "False"},bT)
    1.56    | @{code NOT} p => nott $ (term_of_fm T m m' p)
    1.57    | @{code And} (p,q) => conjt $ (term_of_fm T m m' p) $ (term_of_fm T m m' q)
    1.58    | @{code Or} (p,q) => disjt $ (term_of_fm T m m' p) $ (term_of_fm T m m' q)