rspec/rules/S1538/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

33 lines
599 B
Plaintext

== Why is this an issue?
``++return++``, ``++break++``, ``++continue++``, and ``++throw++`` statements should be followed by a ``++}++``, ``++case++``, or ``++default++``.
----
function sayHello() {
if (true) {
return;
var b; // Non-Compliant - this will never be executed
} else {
var c;
}
while (true) {
break;
var d; // Non-Compliant - this will never be executed
}
}
----
ifdef::env-github,rspecator-view[]
'''
== Comments And Links
(visible only on this page)
=== on 20 Aug 2014, 17:52:40 Ann Campbell wrote:
deprecated
endif::env-github,rspecator-view[]