Issue #2661: Enforce StaticMethodCandidateCheck of sevntu-checkstyle over Checkstyle source code

This commit is contained in:
Andrei Selkin 2015-12-15 00:54:02 +03:00 committed by Roman Ivanov
parent e54822d513
commit 1ef123bf60
2 changed files with 2 additions and 1 deletions

View File

@ -6,5 +6,6 @@
<module name="Checker">
<module name="TreeWalker">
<module name="StaticMethodCandidate"/>
</module>
</module>

View File

@ -303,7 +303,7 @@ public class FinalLocalVariableCheck extends Check {
* @param ast the variable ast.
* @return true, if the variable should be removed.
*/
private boolean shouldRemoveVariable(ScopeData scopeData, DetailAST ast) {
private static boolean shouldRemoveVariable(ScopeData scopeData, DetailAST ast) {
boolean shouldRemove = true;
for (DetailAST variable : scopeData.uninitializedVariables) {
if (variable.getText().equals(ast.getText())) {