boolean (PsiField field, PsiMethod method) { for (PsiReference reference : ReferencesSearch.search(field, new LocalSearchScope(method))) { if (reference instanceof PsiReferenceExpression && PsiUtil.isOnAssignmentLeftHand((PsiReferenceExpression)reference)) { return true; } } return false; }