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


Dependent USING

HLASM Language Reference
SC26-4940-06

To end the domain of a dependent USING instruction, you must end the domain of the corresponding ordinary USING instruction. In the following example, the DROP instruction prevents the assembler from using register 12 as a base register. The DROP instruction causes the assembler to end the domain of the ordinary USING instruction and the domains of the two dependent USING instructions. The storage areas represented by INREC and OUTREC are both within the range of the ordinary USING instruction (register 12).
         USING           *,12
         USING           RECMAP,INREC
         USING           RECMAP,OUTREC
         .
         .
         DROP            12
         .
         .
INREC    DS              CL156
OUTREC   DS              CL156
To end the domain of a labeled dependent USING instruction, you can code a DROP instruction with the USING label in the operand. The following example shows this:
         USING           *,12
PRIOR    USING           RECMAP,INREC
POST     USING           RECMAP,OUTREC
         .
         .
         DROP            PRIOR,POST
         .
         .
INREC    DS              CL156
OUTREC   DS              CL156

In the above example, the DROP instruction makes the labels PRIOR and POST unavailable as symbol qualifiers.

When a labeled dependent USING domain is dropped, none of any subordinate USING domains are dropped. In the following example the labeled dependent USING BLBL1 is not dropped, even though it is dependent on the USING ALBL2 that is dropped:
         USING           DSECTA,14
ALBL1    USING           DSECTA,14
         USING           DSECTB,ALBL1.A
         .
         .
ALBL2    USING           DSECTA,ALBL1.A
         .
BLBL1    USING           DSECTA,ALBL2.A+4
         .
         DROP            ALBL2
         .
DSECTA   DSECT
A        DS              A
DSECTB   DSECT
B        DS              A
A DROP instruction is not needed:
  • If the base address is being changed by a new ordinary USING instruction, and the same base register is assigned. However, the new base address must be loaded into the base register by an appropriate sequence of instructions.
  • If the base address is being changed by a new labeled USING instruction or a new labeled dependent USING instruction, and the same USING label is assigned. The correct base address must be loaded into the base register specified in the USING instruction by an appropriate sequence of instructions.
  • At the end of a source module

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014