public static boolean isOne(@Nullable PsiExpression expression) {
    if (expression == null) {
      return false;
    }
    final Object value = computeConstantExpression(expression);
    if (value == null) {
      return false;
    }
    //noinspection FloatingPointEquality
    return value instanceof Double dValue && dValue == 1.0 ||
           value instanceof Float fValue && fValue == 1.0f ||
           value instanceof Integer iValue && iValue == 1 ||
           value instanceof Long lValue && lValue == 1L ||
           value instanceof Short sValue && sValue == 1 ||
           value instanceof Character cValue && cValue == 1 ||
           value instanceof Byte bValue && bValue == 1;
  }
public static boolean isOne(@Nullable PsiExpression expression)