void (@NotNull PsiMethodCallExpression call) { if (!isRedundantToString(call)) return; final PsiReferenceExpression methodExpression = call.getMethodExpression(); PsiElement referenceNameElement = methodExpression.getReferenceNameElement(); if (referenceNameElement == null) return; PsiExpression qualifier = ExpressionUtils.getEffectiveQualifier(methodExpression); if (qualifier == null) return; if (notNullQualifierOnly && PsiTreeUtil.isAncestor(methodExpression, qualifier, true) && NullabilityUtil.getExpressionNullability(qualifier, true) != Nullability.NOT_NULL) { return; } registerError(referenceNameElement, qualifier.isPhysical() ? null : qualifier.getText()); }