rspec/rules/S1117/java/rule.adoc
2022-02-04 16:28:24 +00:00

38 lines
821 B
Plaintext

include::../description.adoc[]
== Noncompliant Code Example
[source,java]
----
class Foo {
public int myField;
public void doSomething() {
int myField = 0;
...
}
}
----
== See
* https://wiki.sei.cmu.edu/confluence/display/c/DCL01-C.+Do+not+reuse+variable+names+in+subscopes[CERT, DCL01-C.] - Do not reuse variable names in subscopes
* https://wiki.sei.cmu.edu/confluence/display/java/DCL51-J.+Do+not+shadow+or+obscure+identifiers+in+subscopes[CERT, DCL51-J.] - Do not shadow or obscure identifiers in subscopes
ifdef::env-github,rspecator-view[]
'''
== Implementation Specification
(visible only on this page)
include::../message.adoc[]
include::../highlighting.adoc[]
'''
== Comments And Links
(visible only on this page)
include::../comments-and-links.adoc[]
endif::env-github,rspecator-view[]