rspec/rules/S1684/cobol/rule.adoc
Fred Tingaud 16f6c0aecf
Inline adoc when include has no additional value (#1940)
Inline adoc files when they are included exactly once.

Also fix language tags because this inlining gives us better information
on what language the code is written in.
2023-05-25 14:18:12 +02:00

63 lines
1.1 KiB
Plaintext

== Why is this an issue?
TODO
=== Noncompliant code example
[source,cobol]
----
PERFORM UNTIL FIN-RGL0
PERFORM DEBUT-RGL0
PERFORM UNTIL FIN-RGL1
PERFORM DEBUT-RGL1
PERFORM UNTIL FIN-RGL2
PERFORM DEBUT-RGL2
PERFORM ALIM-RGL2
PERFORM FIN-RGL2
END-PERFORM
PERFORM FIN-RGL1
END-PERFORM
PERFORM FIN-RGL0
END-PERFORM
----
=== Compliant solution
[source,cobol]
----
PERFORM TRAITEMENT-RGL0 UNTIL FIN-RGL0.
TRAITEMENT-RGL0.
PERFORM DEBUT-RGL0
PERFORM TRAITEMEN-RGL1 UNTIL FIN-RGL1
PERFORM FIN-RGL0
.
TRAITEMENT-RGL1.
PERFORM DEBUT-RGL1
PERFORM UNTIL FIN-RGL2
PERFORM DEBUT-RGL2
PERFORM ALIM-RGL2
PERFORM FIN-RGL2
END-PERFORM
PERFORM FIN-RGL1
----
ifdef::env-github,rspecator-view[]
'''
== Comments And Links
(visible only on this page)
=== duplicates: S134
=== relates to: S1306
=== on 13 May 2014, 08:39:41 Freddy Mallet wrote:
Might in fact duplicates RSPEC-134
=== on 13 May 2014, 08:49:01 Ann Campbell wrote:
Given the way RSPEC-134 was implemented, this is indeed a duplicate.
endif::env-github,rspecator-view[]