void (@NotNull PsiNewExpression expression) { super.visitNewExpression(expression); final PsiExpressionList argumentList = expression.getArgumentList(); if (argumentList == null) { return; } final PsiExpression[] arguments = argumentList.getExpressions(); if (arguments.length != 1) { return; } final PsiExpression argument = arguments[0]; final PsiType type = argument.getType(); if (!PsiTypes.charType().equals(type)) { return; } final PsiMethod constructor = expression.resolveConstructor(); if (constructor == null) { return; } final PsiClass aClass = constructor.getContainingClass(); if (!InheritanceUtil.isInheritor(aClass, CommonClassNames.JAVA_LANG_ABSTRACT_STRING_BUILDER)) { return; } registerNewExpressionError(expression, argument); }