rspec/rules/S2269/cobol/rule.adoc

34 lines
1.1 KiB
Plaintext
Raw Normal View History

2021-04-28 16:49:39 +02:00
To ensure future code portability, obsolete keywords should not be used. The following keywords were declared obsolete in the COBOL ANSI-85 standard and removed in the ISO/IEC 1989:2002 standard:
* Paragraphs: ``++AUTHOR++``, ``++INSTALLATION++``, ``++DATE-WRITTEN++``, ``++DATE-COMPILED++``, ``++SECURITY++``
* Clauses: ``++DATA RECORD(S)++``, ``++LABEL RECORD(S)++``, ``++MEMORY SIZE++``, ``++MULTIPLE FILE (TAPE)++``, ``++RERUN++``, ``++VALUE OF++``, ``++CODE SEGMENT-LIMIT++``
* Statements: ``++ALTER++``, ``++ENTER++``, ``++STOP++`` _literal_, ``++GO TO++`` without an argument
* Phrases: ``++REVERSED++`` phrase of the ``++OPEN++`` statement
* Special registers: ``++DEBUG-ITEM++``
* Sections: Debugging sections
* Declarative: ``++USE FOR DEBUGGING++``
The following keywords were declared obsolete in the ISO/IEC 1989:2002 standard:
* Phrase: ``++DEBUGGING MODE++``
* Clause: ``++PADDING CHARACTER++``
2021-04-28 16:49:39 +02:00
== Noncompliant Code Example
----
IDENTIFICATION DIVISION.
PROGRAM-ID. AcceptAndDisplay.
AUTHOR. Michael Coughlan. *> Noncompliant
----
2021-04-28 16:49:39 +02:00
== Compliant Solution
----
IDENTIFICATION DIVISION.
PROGRAM-ID. AcceptAndDisplay.
----