boolean (PsiVariable variable, PsiDeclarationStatement declarationStatement) { final PsiElement[] declaredElements = declarationStatement.getDeclaredElements(); if (declaredElements.length == 1) { return false; } boolean check = false; for (PsiElement declaredElement : declaredElements) { if (!check && variable.equals(declaredElement)) { check = true; } else { if (VariableAccessUtils.variableIsUsed(variable, declaredElement)) { return true; } } } return false; }