There is no reason you can't use DC's in DSECTS instead of DS's. I just code my macros with DC's so they work in either case. I do use &TYPE to determine if the control block initial definition specifies DSECT or DC 0D'0'.
Chuck Arney Arney Computer Systems Web: http://zosdebug.com Facebook: http://www.facebook.com/arneycomputer -----Original Message----- From: IBM Mainframe Assembler List [mailto:[email protected]] On Behalf Of Gary Weinhold Sent: Thursday, October 02, 2014 11:15 AM To: [email protected] Subject: Macro to generate DS or DC I am trying to develop a technique to force a DSECT (describing some private control block of mine) to stay synchronized with the inline-constant and space-reserving versions of the same control block. For example, for DSECT ABC with field definitions of ABCID DS CL4 Eyecatcher ABCLEN DS AL2 Length of ABC ABCLVL DS AL2 ABC modification level ABCDATA DS F Some binary data ABCL EQU (*-ABCID) I would like to be able to generate in-line constants: label1 DS 0F DC CL4'EYEC' DC AL2(ABCL) DC AL2(1) DC F'0' ABCL EQU (*-label1) and space: label2 DS CL(ABCL) The DSDC macro generates a labeled DS statements or unlabeled DC statements depending on &TYPE; its format is, for example: ABCEYE DSDC CL4,C'ABCD','EYECATCHER',&TYPE ABCLEN DSDC AL2,(ABCBLKLN),'LENGTH OF THIS CONTROL BLOCK',&TYPE Although I started work on this with a macro I call DSDC, I was wondering if I'm reinventing the wheel. Is there a model for this out there? Any suggestions are welcome. Gary Weinhold Data Kinetics, Ltd.
