private static boolean isPotentiallyConvertible(@Nullable PsiType leftType,
                                                  @Nullable PsiExpression rightExpr,
                                                  @Nullable PsiType rightType,
                                                  @NotNull PsiElement context) {
    if (leftType instanceof PsiLambdaParameterType || rightType instanceof PsiLambdaParameterType) return true;
    boolean pendingLeft = leftType == null || hasUnresolvedComponent(leftType);
    boolean pendingRight =
      rightType == null || (rightExpr == null ? hasUnresolvedComponent(rightType) : mayHaveUnknownTypeDueToPendingReference(rightExpr));
    if (pendingLeft && pendingRight) return true;
    if (!pendingLeft && !pendingRight) {
      return leftType.isConvertibleFrom(rightType);
    }
    if (pendingLeft && isStrictlyInconvertible(leftType, rightType, context)) {
      return false;
    }
    if (pendingRight && isStrictlyInconvertible(rightType, leftType, context)) {
      return false;
    }
    return true;
  }
private static boolean isPotentiallyConvertible(@Nullable PsiType leftType,
                                                  @Nullable PsiExpression rightExpr,
                                                  @Nullable PsiType rightType,
                                                  @NotNull PsiElement context)