◆V→V1[E]# Indexer I ndexVar: L: =Sem[top-1]; R: Sem[top] ResultArg: =New Temp(indir) Resul tType: =L. Type. Elem Type LOW: =L. Type Low; Size: =L. Type. ElemSize Generate(sUBl, R Arg, Low, t1) Generate MULl, t1, Size, t2) Generate(AADD, L Arg, t2, ResultAr g) POP(2): Push((ResultType, Resultarg)) ◆V→>V1个 iE Denovar DenoVar: ResultArg: =New Temp(indir) ResultType: =Sem[top] Type Base Type Generate(ASSIG, Sem[top]. Arg, ResultArg) POP(1): Push ((ResultType, Resul targ))⬧ V → V 1[E] #IndexVar IndexVar: L:= Sem[top-1]; R:= Sem[top]; ResultArg:=NewTemp(indir); ResultType:= L.Type.ElemType; Low:=L.Type.Low;Size:= L.Type.ElemSize; Generate(SUBI, R.Arg, Low, t1); Generate(MULI, t1, Size, t2); Generate(AADD, L.Arg,t2, ResultArg); POP(2); Push((ResultType,ResultArg)); ⬧ V → V 1 #DenoVar DenoVar: ResultArg:=NewTemp(indir); ResultType:= Sem[top].Type.BaseType; Generate(ASSIG, Sem[top].Arg, ResultArg) POP(1); Push((ResultType, ResultArg))