RSTR statement

The RSTR statement specifies COBOL words that cannot be used in a program, and it can also be used to control the use of nested programs.

RSTR COBOL-word[(0 | 1)] [comments]
By selecting either 1 or 0, you can indicate whether a specific COBOL-word can be used only once, or not at all.
0
Indicates that whenever the specified COBOL-word is used, message 0084 is issued.
1
Indicates that the specified COBOL-word can be used once. If it is used more than once, severe message 0194 is issued.
The following reserved words can be restricted only by using option 1:
  • DATA
  • ENVIRONMENT
  • ID
  • IDENTIFICATION
  • PROGRAM-ID
  • WORKING-STORAGE
  • LOCAL-STORAGE
  • LINKAGE