rspec/rules/S128/noncompliant.adoc

16 lines
332 B
Plaintext

=== Noncompliant code example
[source,text]
----
switch (myVariable) {
case 1:
foo();
break;
case 2: // Both 'doSomething()' and 'doSomethingElse()' will be executed. Is it on purpose ?
doSomething();
default:
doSomethingElse();
break;
}
----