InterpreterPrivate.mesa
Russ Atkinson, April 19, 1983 11:06 am
Paul Rovner, November 1, 1983 9:51 pm
DIRECTORY
AMTypes USING [Class, TV],
InterpreterOps USING [EvalHead, Tree],
Rope USING [ROPE],
SafeStorage USING [Type],
SymTab USING [Ref],
WorldVM USING [World];
InterpreterPrivate: CEDAR DEFINITIONS
= BEGIN OPEN AMTypes, InterpreterOps, Rope, SafeStorage, WorldVM;
GetGlobalSymTab: PROC RETURNS [SymTab.Ref];
GetNilTV: PROC RETURNS [TV];
GetTypeOfSafeStorageDotType: PROC RETURNS [Type];
EvalNoProps: PROC [tree: Tree, head: EvalHead, target: Type] RETURNS [TV];
... is like InterpreterOps.Eval, but no attempt is made to add process properties. This is useful when it is already known that the properties have been added, for example.
RecordSearch: PROC [record: TV, name: ROPE] RETURNS [TV];
EvalRecord: PROC [
args: Tree, head: EvalHead, target: Type, parent: Tree, targetWorld: World ← NIL]
RETURNS [TV];
... evaluates a record constructor. IF targetWorld # NIL THEN the constructor should be made for the given world, even though the arguments get looked up according to the given head.
EnumeratedValueFromRope: PROC
[name: ROPE, type: Type] RETURNS [val: TVNIL];
NumberedMsg: PROC [r1: ROPE, num: INT, r2: ROPENIL] RETURNS [ROPE];
TestAbort: PROC [head: EvalHead, parent: Tree];
GetDefault: PROC [head: EvalHead, parent: Tree, type: Type, index: CARDINAL]
RETURNS [defval: TV];
LocalCoerce: PROC
[head: EvalHead, parent: Tree, current: TV, target: Type,
index: CARDINAL ← 0, msg: ROPENIL]
RETURNS [val: TV];
CoerceTV: PROC [arg: TV, fullType: Type] RETURNS [rtn: TV];
takes a TV and the full type of the expected TV and tries to
return a TV assignable to a TV for the full type
handles cases that RTTypes.Coerce does not handle
also may call RTTypes.Coerce
may raise RTTypes.IncompatibleTypes
UnderTypeAndClass: PROC [type: Type] RETURNS [under: Type, class: Class];
NewInt: PROC [int: INT] RETURNS [tv: TV];
NewReal: PROC [real: REAL] RETURNS [TV];
NewType: PROC [type: Type] RETURNS [TV];
END.