RENT option to compile a reentrant COBOL program

555 views Asked by At

I am new to COBOL programming. I am making changes to a COBOL program which manipulates threads.I have introduced a file in the program to read a set of parameters and use it in the program. But whenever I compile the program I get the following warning:-

*1237-W **Filehandling used with REENTRANT Directive

Now am I supposed to use the RENT option to compile this program? If so, then how should I compile using RENT option ie. the exact commands to be used. Please help.

1

There are 1 answers

1
Stephen Gennard On

The error message number implies you are using Micro Focus COBOL, so depending on the platform you can do:

Unix:

cob -C REENTRANT fred.cbl

Windows:

cobol fred.cbl REENTRANT; cbllink fred.obj

or you can add the option to the actual source code itself eg:

  $set REENTRANT