View previous topic :: View next topic
|
Author |
Message |
Mohan raj
New User
Joined: 08 Aug 2009 Posts: 1 Location: Chennai
|
|
|
|
Hi,
I need severe error in compilation for Redefining a smaller item in "IBM Enterprise COBOL for z/OS 3.4.0". I am using the IGYCRCTL compiler.
Example:
05 VAR-A PIC X(5).
05 VAR-B REDEFINES VAR-A PIC X(10).
In compilation it is just giving a Warning message. Is it possible for me to get a SEVERE error in "Enterprise COBOL for z/OS 3.4.0" itself by using any compiler option.
Note : "IBM COBOL for OS/390 & VM 2.2.1" is giving SEVERE error.
Thanks. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
|
|
|
|
I've never heard of any way to control the severity level of compiler messages -- what they are set by IBM is what they are, period. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1249 Location: Richfield, MN, USA
|
|
|
|
Although it's not a good practice (in my opinion) to redefine a smaller area, I understand that the Enterprise compiler, unlike previous compilers, will allocate memory equal to the larger definition, so I wouldn't worry about it. As a rule, I add a filler to the smaller area to document the situation for the next maintainer. |
|
Back to top |
|
|
fairplay27
New User
Joined: 20 Mar 2009 Posts: 1 Location: Italy
|
|
|
|
Some years after this thread I may read in the manuals that it's possible to change some compiler message severity:
For Cobol 5.2 :
Cobol 5.2 Programming Guide
...
As examples, you can:
...
Disallow REDEFINING a smaller item with a larger item by raising the severity of message 1154.
... |
|
Back to top |
|
|
|