ack/lang/a68s/liba68s/scopext.p

33 lines
1 KiB
OpenEdge ABL
Raw Permalink Normal View History

1988-10-04 13:41:01 +00:00
46000 #include "rundecs.h"
46010 (* COPYRIGHT 1983 C.H.LINDSEY, UNIVERSITY OF MANCHESTER *)
46020 (**)
46030 (**)
46040 FUNCTION STRUCTSCOPE(STRUCTPTR: UNDRESSP; TEMPLATE: DPOINT):DEPTHRANGE; EXTERN;
46050 FUNCTION MULTSCOPE(MULT: OBJECTP):DEPTHRANGE; EXTERN;
46060 PROCEDURE ERRORR(N :INTEGER); EXTERN ;
46070 (**)
46080 (**)
46090 FUNCTION SCOPEXT(SOURCE: OBJECTP): OBJECTP;
46100 (*PSCOPEEXT*)
46110 VAR SOURCESCOPE: DEPTHRANGE;
46120 BEGIN
46130 WITH SOURCE^ DO
46140 IF OSCOPE=0 THEN
46150 IF SORT=STRUCT THEN
46160 BEGIN
46170 SOURCESCOPE := STRUCTSCOPE(INCPTR(SOURCE, STRUCTCONST), DBLOCK);
46180 OSCOPE := SOURCESCOPE
46190 END
46200 ELSE SOURCESCOPE := MULTSCOPE(SOURCE)
46210 ELSE SOURCESCOPE := OSCOPE;
46220 IF SCOPE+FIRSTRG.RIBOFFSET^.RGSCOPE<=SOURCESCOPE THEN ERRORR(RSCOPE);
46230 SCOPEXT := SOURCE;
46240 END;
46250 (**)
46260 (**)
46270 (*-02() BEGIN END ; ()-02*)
46280 (*+01()
46290 BEGIN (*OF MAIN PROGRAM*)
46300 END (*OF EVERYTHING*).
46310 ()+01*)