void (@NotNull PsiAssignmentExpression expression) { PsiJavaToken sign = expression.getOperationSign(); IElementType tokenType = sign.getTokenType(); if (tokenType == null || !SUPPORTED_SIGNS.contains(tokenType)) { return; } PsiExpression rExpression = expression.getRExpression(); PsiExpression lExpression = expression.getLExpression(); if (rExpression == null) { return; } PsiType lType = lExpression.getType(); PsiType rType = rExpression.getType(); if (lType == null || rType == null) { return; } if (!(TypeConversionUtil.isPrimitiveAndNotNull(lType) && TypeConversionUtil.isNumericType(lType) && TypeConversionUtil.isNumericType(rType) )) { return; } if (TypeConversionUtil.areTypesAssignmentCompatible(lType, rExpression) || !TypeConversionUtil.areTypesConvertible(rType, lType)) { return; } registerError(rExpression, rType, lType, rExpression); }