WITH opRec
SELECT
FROM
bc: TOR.FRBreakCross => RETURN [BreakCross[top, bc.refCh, bc.chToBreak, keepTrack].ir];
fc: TOR.FRFormCross => RETURN [FormCross[top, fc.ch1, fc.ch2, keepTrack].ir];
fz: TOR.FRFormZ => RETURN [FormZ[top, fz.comp1, fz.comp2, fz.zType, keepTrack].ir];
rz: TOR.FRRemoveZ => RETURN [RemoveZ[top, rz.zSpine, keepTrack].ir];
lt: TOR.FRLtoT => RETURN [LtoT[top, lt.ch, lt.whichEnd, keepTrack].ir];
tl: TOR.FRTtoL => RETURN [TtoL[top, tl.co, tl.ch, tl.lType, keepTrack].ir];
fk: TOR.FRFlexKnee => RETURN [FlexKnee [top, fk.leg, fk.floor, fk.whichEnd, keepTrack].ir];
ek: TOR.FRExtendKnee => RETURN [ExtendKnee [top, ek.shin, keepTrack].ir];
ft: TOR.FRFlipT => RETURN[FlipT[top, ft.chToBend, ft.attachTo, ft.whichEnd, keepTrack].ir];
g1: TOR.FRGrow1 => RETURN [Grow1 [top, g1.co, g1.host, g1.hostCorner, keepTrack].ir];
s1: TOR.FRShrink1 => RETURN [IPTopOpsPrivate.Shrink1 [top, s1.co, keepTrack].ir];
ic: TOR.FRInsertCo => RETURN [IPTopOpsPrivate.InsertCo [top, ic.co, ic.chToSplit, ic.negBnd, ic.posBnd, ic.sideHint, ic.whichFirstHint, keepTrack].ir];
rc: TOR.FRRemoveCo => RETURN [IPTopOpsPrivate.RemoveCo [top, rc.co, rc.shrinkDirectn, keepTrack].ir];
or: TOR.ROrient => RETURN [Orient[top, or.co, or.operation, keepTrack].ir];
sc: TOR.RSetComponent => RETURN [SetComponent[top, sc.co, sc.active, sc.atPosition, keepTrack].ir];
tc: TOR.RMoveComponent => RETURN [MoveComponent[top, tc.co, tc.by, keepTrack].ir];
sc: TOR.RSwapComponents => RETURN [SwapComponents[top, sc.comp1, sc.comp2, keepTrack].ir];
sc: TOR.FRSpawnComps => RETURN [SpawnComps[top, sc.comp, NIL, NIL, [], [], sc.splitDirection, sc.chkArgs, keepTrack, sc.negChild, sc.posChild].ir];
scs: TOR.RSetCompShape => RETURN [SetCompShape[top, scs.comp, scs.shape, scs.chkArgs, keepTrack].ir];
com:
TOR.RComposite => {l:
LIST
OF
REF ←
NIL;
FOR comRev:
TOR.RComposite ← LReverse[com], comRev.rest
UNTIL comRev =
NIL
DO
l ← CONS[RedoDiscrmOpRec[top, comRev.first, FALSE], l];
ENDLOOP;
IF keepTrack THEN PushStacks[top, com, l];
RETURN [l]};
ENDCASE => ERROR;