On Mon, 5 Apr 2021 at 18:35, Bernd Oppolzer <[email protected]> wrote: > > Thank you, I found the solution myself - dependent USINGs - > see Chapter XI of Dr. John Ehrman's excellent book "Assembler Language > Programming ..."
I was going to suggest this. There is another technique that we have in some of our older code that predates the standard use of Assembler H. (Yes, I know - that's old!) Many of our mapping macros have a PREFIX= option, and such a macro simply contains statements like &PREFIX.MAPA DSECT &PREFIX.MAPA_Field1 DS D &PREFIX.MAPA_Field2 DS CL8 and so on. Of course PREFIX can be, and in fact defaults to, null. There is also a DSECT=[YES | NO] option, which defaults to YES. So typically there is one default expansion with PREFIX= and DSECT=YES, and one or more others with e.g. PREFIX=#New or PREFIX=LOCAL_ or whatever. You can expand one of these in your CSECT space with DSECT=NO, and it will actually reserve the space. Others with DSECT=YES will provide the mapping only. Then you can do MVC #NewMAPA_Field2,LOCAL_MAPA_Field2 and the like. You can go further and use DCs instead of DSs, and then the CSECT copy can contain init values. A poor man's dependent USING, I guess. Tony H.
