WITH str
SELECT
FROM
enum: M2D.EnumPtr =>
{ WriteNo [STR+enumBlk]; WriteNo [enum^.size];
WriteNo [enum^.NofConst] };
range: M2D.RangePtr =>
{ IF range^.BaseTyp^.ref = 0 THEN OutStr [range^.BaseTyp];
WriteNo [STR+rangeBlk]; WriteNo [range^.size];
WriteNo [range^.BaseTyp^.ref];
WriteNo [LOOPHOLE[range^.min, CARDINAL]];
WriteNo [LOOPHOLE[range^.max, CARDINAL]] };
pointer: M2D.PointerPtr =>
{ obj ← NEW [M2D.Object.Linkage ← [
typ: pointer^.BaseTyp, ext: Linkage [baseref: CurStr]]];
LinkList^.last^.next ← obj; LinkList^.last ← obj;
WriteNo [STR+pointerBlk]; WriteNo [pointer^.size] };
set: M2D.SetPtr =>
{ IF set^.BaseTyp^.ref = 0 THEN OutStr [set^.BaseTyp];
WriteNo [STR+setBlk]; WriteNo [set^.size]; WriteNo [set^.BaseTyp^.ref] };
proctyp: M2D.ProcTypPtr =>
{ FOR par: M2D.ParPtr ← proctyp^.firstPar, par^.next WHILE par # NIL DO
-- out parameter structure --
IF par^.typ^.ref = 0 THEN OutStr [par^.typ];
ENDLOOP;
OutPar [proctyp^.firstPar];
IF proctyp^.resTyp = M2D.notyp THEN -- ordinary procedure --
{ WriteNo [STR+procTypBlk]; WriteNo [proctyp^.size] }
ELSE -- function --
{ IF proctyp^.resTyp^.ref = 0 THEN OutStr [proctyp^.resTyp];
WriteNo [STR+funcTypBlk]; WriteNo [proctyp^.size];
WriteNo [proctyp^.resTyp^.ref] }};
array: M2D.ArrayPtr =>
{ IF array^.ElemTyp^.ref = 0 THEN OutStr [array^.ElemTyp];
IF NOT array^.dyn THEN
{ IF array^.IndexTyp^.ref = 0 THEN OutStr [array^.IndexTyp];
WriteNo [STR+arrayBlk]; WriteNo [array^.size];
WriteNo [array^.ElemTyp^.ref]; WriteNo [array^.IndexTyp^.ref] }
ELSE
{ WriteNo [STR+dynarrBlk]; WriteNo [array^.size];
WriteNo [array^.ElemTyp^.ref] }};
record: M2D.RecordPtr =>
{ obj ← record^.firstFld;
WHILE obj # NIL DO -- out field structure --
IF obj^.typ^.ref = 0 THEN OutStr [obj^.typ];
obj ← obj^.next
ENDLOOP;
obj ← record^.firstFld;
WHILE obj # NIL DO -- out fields --
field: M2D.FieldPtr = NARROW [obj];
WriteNo [CMP+fieldBlk]; WriteNo [obj^.typ^.ref];
WriteNo [field^.offset]; WriteId [obj^.name];
obj ← obj^.next
ENDLOOP;
WriteNo [STR+recordBlk]; WriteNo [record^.size] };
opaque: M2D.OpaquePtr =>
{ WriteNo [STR+opaqueBlk]; WriteNo [opaque^.size] }