To remove the necessity of placing a marker word at the end of null files it is suggested that a length of file function, LNFL, be created. Thus:
(a) LOAD ('P1', ANAME( 'FILENAME')) LOAD ('P2',1.0) LOAD ('P3',1.0) LNFL ('LEN','P1','P2') WHILE('P3','LE','LEN') BEGINS LOAD ('X',AR('P1','P2','P3')) ADD('P3','1.0) LOAD ('Y',AR('P1','P2','P3')) ADD ('P3',1.0) SETXY('X''Y') ADUFLM ENDS
The above example could be simplified by the addition of an execute command, XCT. The loop becomes:
(b) LOAD('NOARGS',2.0) NULLSET(DSRTNM('SETXY')) WHILE('P3',LE,LEN) BEGINS XCT(P1,P2,P3) ADD ('P3',PR2(NOARGS)) ADUFLM ENDS
XCT takes an array of index variable as its argument. It causes the NULLSET instruction to be executed with the arguments pointed to by the array. Thus, it is really a primitive form of DRAW on a NULL file. Another command XCTA (execute and add) would XCT then increment the third member of the array by the number of arguments in the command specified by NULLSET. Thus (b) becomes
(c) NULLSET (DSRTN:' SETXY')) WHILE('PS',LE,LEN) BEGINS XCTA('P1','P2','P3') ADUFLM ENDS
Thus, XCTA causes a 'SETXY' on each pair of arguments in the NULL file and increments P3 by 2.