How do I concatenate the GBLB variable name using 2 variables?
I'm writing a data macro (DSECT) that I want to suffix.
the GBLB really needs to be something like &MYMAC&SUF to set/check the global if I've already called the macro with this suffix.
I'm thinking that I can set a
GBLA &MAC
&MAC SETA C'MYMAC'
GBLB &MAC&SUF
...
&MAC&SUF SETB 1
...
IF(&MAC&SUF.1).AGO .SKIP
How do I concatenate the GBLB variable name using 2 variables?
MACRO
MYMAC ®,&SUF
GBLB &SFX
AIF (&SFX.1).AGO .SKIP
MYMAC&SUF DSECT
ALAB1&SUF DS CL5
ALAB2&SUF DS CL10
.SKIP ANOP
USING MYMAC&SUF,®
&SFX SETB 1
MEND
MYMAC REG=1,SUF=IN
MYMAC REG=2,SUF=OUT
....
MYMAC REG=3,SUF=IN
MYMAC ®,&SUF
GBLB &SFX
AIF (&SFX.1).AGO .SKIP
MYMAC&SUF DSECT
ALAB1&SUF DS CL5
ALAB2&SUF DS CL10
.SKIP ANOP
USING MYMAC&SUF,®
&SFX SETB 1
MEND
MYMAC REG=1,SUF=IN
MYMAC REG=2,SUF=OUT
....
MYMAC REG=3,SUF=IN