HLASM Language Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Multilevel sublists

HLASM Language Reference
SC26-4940-06

You can specify multilevel sublists (sublists within sublists) in macro operands. The depth of this nesting is limited only by the constraint that the total operand length must not exceed 1024 characters. Inner elements of the sublists are referenced using additional subscripts on symbolic parameters or on &SYSLIST.

N'&SYSLIST(n) gives the number of operands in the indicated n-th level sublist. The number attribute (N') and a parameter name with an n-element subscript array gives the number of operands in the indicated (n+1)-th operand sublist. Table 1 shows the value of selected elements if &P is the first positional parameter, and the value assigned to it in a macro instruction is (A,(B,(C)),D).

Table 1. Multilevel sublists
Selected Elementsfrom &P Selected Elementsfrom &SYSLIST Value ofSelected Element

&P
&P(1)
&P(2)
&P(2,1)
&P(2,2)
&P(2,2,1)
&P(2,2,2)
N'&P(2,2)
N'&P(2)
N'&P(3)
N'&P
 

&SYSLIST(1)
&SYSLIST(1,1)
&SYSLIST(1,2)
&SYSLIST(1,2,1)
&SYSLIST(1,2,2)
&SYSLIST(1,2,2,1)
&SYSLIST(1,2,2,2)
N'&SYSLIST(1,2,2)
N'&SYSLIST(1,2)
N'&SYSLIST(1,3)
N'&SYSLIST(1)
 

(A,(B,(C)),D)
A
(B,(C))
B
(C)
C
null
1
2
1
3
 

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014