CraigJConrad
IS-IT--Management
Hi,
I have my COBOL code on MVS, broken down into many PDS members, using COPY statements to pull the pieces together in the compile step. I'd like a tool/utility that will resolve all of the COPY statements, replacing them with the COPY'd member, leaving me with a single file that is a complete COBOL program (compiler-ready).
If done the "obvious" way of iterating through the code, finding a COPY, fetching the identified member and writing it out, etc ... then nested COPY would work, but any COPY REPLACING would not be resolved without further coding. This could get complex (I have no real use of the REPLACING at this time, so it would be ok for now).
However, it seems that the compiler should be able to provide the intermediate COBOL code -- after it has handled all the COPY statements, just before it goes to the real compile step. Is there a way to get the mainframe compiler (e.g. a current IBM Cobol compiler) to give me this file?
A colleague has suggested getting the listing from the compiler and re-formatting (removing the page heading/trailers, cropping the non-code space on left/right of each line, etc), but I'd prefer a cleaner approach.
Ideas? Thanks in advance ... Craig
I have my COBOL code on MVS, broken down into many PDS members, using COPY statements to pull the pieces together in the compile step. I'd like a tool/utility that will resolve all of the COPY statements, replacing them with the COPY'd member, leaving me with a single file that is a complete COBOL program (compiler-ready).
If done the "obvious" way of iterating through the code, finding a COPY, fetching the identified member and writing it out, etc ... then nested COPY would work, but any COPY REPLACING would not be resolved without further coding. This could get complex (I have no real use of the REPLACING at this time, so it would be ok for now).
However, it seems that the compiler should be able to provide the intermediate COBOL code -- after it has handled all the COPY statements, just before it goes to the real compile step. Is there a way to get the mainframe compiler (e.g. a current IBM Cobol compiler) to give me this file?
A colleague has suggested getting the listing from the compiler and re-formatting (removing the page heading/trailers, cropping the non-code space on left/right of each line, etc), but I'd prefer a cleaner approach.
Ideas? Thanks in advance ... Craig