rspec/rules/S1570/cobol/rule.adoc

21 lines
425 B
Plaintext
Raw Normal View History

== Why is this an issue?
2021-04-28 16:49:39 +02:00
Using a data value clause in the ``++LINKAGE SECTION++`` can lead to unexpected behavior at runtime.
=== Noncompliant code example
2021-04-28 16:49:39 +02:00
2022-02-04 17:28:24 +01:00
[source,cobol]
2021-04-28 16:49:39 +02:00
----
LINKAGE SECTION.
01 CAR-ID PIC X(20) VALUE IS "VOLVO". *> Noncompliant
01 EMP-TYPE PIC X.
88 FULL-TIME-EMPLOYEE VALUE "F". *> Compliant; this is a condition name
88 PART-TIME-EMPLOYEE VALUE "P".
01 TRAIN-ID PIC X(20)
----