static @Nullable DfType fromConstant(@NotNull PsiExpression constant) {
    if (constant instanceof PsiClassObjectAccessExpression classObject) {
      PsiTypeElement operand = classObject.getOperand();
      return DfTypes.referenceConstant(operand.getType(), classObject.getType());
    }
    if (constant instanceof PsiReferenceExpression refExpr) {
      PsiElement target = refExpr.resolve();
      if (target instanceof PsiEnumConstant) {
        return DfTypes.referenceConstant(target, Objects.requireNonNull(constant.getType()));
      }
    }
    if (ExpressionUtils.isNullLiteral(constant)) {
      return DfTypes.NULL;
    }
    Object value = ExpressionUtils.computeConstantExpression(constant);
    if (value != null) {
      return DfTypes.constant(value, Objects.requireNonNull(constant.getType()));
    }
    return null;
  }
static @Nullable DfType fromConstant(@NotNull PsiExpression constant)