Problems compiling both RPG and CBL source in same model

Document ID : KB000093107
Last Modified Date : 26/04/2018
Show Technical Document Details
Issue:
Problems compiling both RPG and CBL source in same model.   Can generate and compile in CBL but not RPG or RP4 within the same model.  Gen compile errors such as:

RNS9308: 
Message . . . . :   Compilation stopped. Severity 40 errors found in program.
Cause . . . . . :   The RPG compiler found at least one error in the program of severity greater than that specified in the GENLVL option on the CRTRPGMOD or CRTBNDRPG command. 
Recovery  . . . :   Correct the errors in the program. Compile again.
Resolution:
It is possible to generate/compile using either RPG/RP4 or CBL in the same model. The problem in this case was that the model was defined with the Function Format Names and Source Member Names as being the same name.  This works ok for CBL generation and compile, but will fail with RPG or RP4 generation and compile.