boolean (PsiCodeBlock containingScope, PsiExpression qualifier, PsiVariable variable) { while (variable != null) { if (!variable.hasModifierProperty(PsiModifier.FINAL) && variableIsAssigned(variable, containingScope, false)) { return true; } if (!(qualifier instanceof PsiReferenceExpression qualifierReference)) break; qualifier = PsiUtil.skipParenthesizedExprDown(qualifierReference.getQualifierExpression()); variable = ObjectUtils.tryCast(qualifierReference.resolve(), PsiVariable.class); } return false; }