void (@NotNull PsiField field) { if (field.hasModifierProperty(PsiModifier.STATIC) || field.hasModifierProperty(PsiModifier.FINAL)) { return; } if (field.getInitializer() != null) { return; } final PsiAnnotation annotation = AnnotationUtil.findAnnotation(field, annotationNames); if (annotation != null) { return; } if (m_ignorePrimitives) { final PsiType fieldType = field.getType(); if (ClassUtils.isPrimitive(fieldType)) { return; } } final PsiClass aClass = field.getContainingClass(); if (aClass == null) { return; } if (UnusedSymbolUtil.isImplicitWrite(field)) { return; } final UninitializedReadCollector uninitializedReadsCollector = new UninitializedReadCollector(); if (!isInitializedInInitializer(field, uninitializedReadsCollector)) { final PsiMethod[] constructors = aClass.getConstructors(); for (final PsiMethod constructor : constructors) { final PsiCodeBlock body = constructor.getBody(); uninitializedReadsCollector.blockAssignsVariable(body, field); } } final PsiExpression[] badReads = uninitializedReadsCollector.getUninitializedReads(); for (PsiExpression expression : badReads) { registerError(expression, field); } }