src/HOL/TLA/Memory/MemClerkParameters.thy
author wenzelm
Fri, 06 Oct 2000 17:35:58 +0200
changeset 10168 50be659d4222
parent 6255 db63752140c7
child 11703 6e5de8d4290a
permissions -rw-r--r--
final tuning;

(*
    File:        MemClerkParameters.thy
    Author:      Stephan Merz
    Copyright:   1997 University of Munich

    Theory Name: MemClerkParameters
    Logic Image: TLA

    RPC-Memory example: Parameters of the memory clerk.
*)

MemClerkParameters = RPCParameters + 

datatype  mClkState  =  clkA | clkB

types
  (* types sent on the clerk's send and receive channels are argument types
     of the memory and the RPC, respectively *)
  mClkSndArgType   = "memOp"
  mClkRcvArgType   = "rpcOp"

constdefs
  (* translate a memory call to an RPC call *)
  MClkRelayArg     :: "memOp => rpcOp"
    "MClkRelayArg marg == memcall marg"
  (* translate RPC failures to memory failures *)
  MClkReplyVal     :: "Vals => Vals"
    "MClkReplyVal v == if v = RPCFailure then MemFailure else v"

end