DIRECTORY AMTypes USING [TV], AMModel USING [Context], Rope USING [ROPE], SymTab USING [Ref]; Interpreter: CEDAR DEFINITIONS = BEGIN OPEN AMModel, Rope, AMTypes; AbortClosure: TYPE = RECORD [proc: AbortProc, data: REF _ NIL]; nilAbortClosure: AbortClosure = [NIL, NIL]; AbortProc: TYPE = PROC [data: REF] RETURNS [abort: BOOL _ FALSE]; Evaluate: PROC [rope: ROPE, context: Context _ NIL, -- NIL means use AMModel.RootContext[LocalWorld[]] symTab: SymTab.Ref _ NIL, -- look here first for name to TV lookup abort: AbortClosure _ nilAbortClosure -- default is to never abort ] RETURNS[result: TV, errorRope: ROPE, noResult: BOOL]; EvaluateToRope: PROC [rope: ROPE, context: Context _ NIL, -- NIL means use AMModel.RootContext[LocalWorld[]] symTab: SymTab.Ref _ NIL, -- look here first for name to TV lookup abort: AbortClosure _ [NIL, NIL] -- default is to never abort ] RETURNS[result: ROPE, errorRope: ROPE, noResult: BOOL]; END. ¢Interpreter.mesa Paul Rovner, July 25, 1983 10:25 am This is called by Evaluate at intervals to ask whether it should abort its task and return. USING THE INTERPRETER ... parses and interprets the given rope as a Mesa expression, returning a TV for the result (noResult is TRUE if there is no result). ... is just like Evaluate, except that the result is a ROPE produced by IO.PutTV with defaulted arguments. ÊÁ˜JšÏi œ™Jšœ#™#˜šÏk ˜ Jšœžœžœ˜Jšœžœ ˜Jšœžœžœ˜Jšœžœ˜—J˜šœ žœž ˜Jšœžœžœ˜$—™Jšœ\™\—š œžœžœžœžœ˜?Jšœ!žœžœ˜+JšÏn œžœžœžœžœ žœžœ˜A—J˜™šŸœž˜Jšœžœ˜ JšœžœÏc2˜LJšœžœ (˜DJšœ( ˜DJšœ˜Jšžœ žœ žœ žœ˜5Jšœ†™†—J˜šŸœž˜Jšœžœ˜ Jšœžœ 2˜LJšœžœ (˜DJšœžœžœ ˜?Jšœ˜Jšžœ žœ žœ žœ˜7Jšœ7žœ/™j—J˜—Jšžœ˜—J˜—…—¶