definition start_sheap_preloaded :: "'m prog ==> sheap" where "start_sheap_preloaded P ≡ fold (λ(C,cl) f. f(C := Some (sblank P C, Prepared))) P (λx. None)"
subsection‹ Frame Stack ›
datatype init_call_status = No_ics | Calling cname "cname list"
| Called "cname list" | Throwing "cname list" addr
― ‹@{text "No_ics"} = not currently calling or waiting for the result of an initialization procedure call›
― ‹@{text "Calling C Cs"} = current instruction is calling for initialization of classes @{text "C#Cs"} (last class
is the original) -- still collecting classes to be initialized, @{text "C"} most recently collected›
― ‹@{text "Called Cs"} = current instruction called initialization and is waiting for the result
-- now initializing classes in the list›
― ‹@{text "Throwing Cs a"} = frame threw or was thrown an error causing erroneous end of initialization
procedure for classes @{text "Cs"}›
type_synonym
frame = "val list × val list × cname × mname × pc × init_call_status"
― ‹operand stack›
― ‹registers (including this pointer, method parameters, and local variables)›
― ‹name of class where current method is defined›
― ‹current method›
― ‹program counter within frame›
― ‹indicates frame's initialization call status›
translations
(type) "frame" <= (type) "val list × val list × char list × char list × nat × init_call_status"
fun curr_stk :: "frame ==> val list"where "curr_stk (stk, loc, C, M, pc, ics) = stk"
fun curr_class :: "frame ==> cname"where "curr_class (stk, loc, C, M, pc, ics) = C"
fun curr_method :: "frame ==> mname"where "curr_method (stk, loc, C, M, pc, ics) = M"
fun curr_pc :: "frame ==> nat"where "curr_pc (stk, loc, C, M, pc, ics) = pc"
fun init_status :: "frame ==> init_call_status"where "init_status (stk, loc, C, M, pc, ics) = ics"
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.