@NotNull
  private static List<@NotNull PyCallableType> multiResolveCalleeFunction(@NotNull PyCallSiteExpression callSite,
                                                                          @NotNull PyResolveContext resolveContext) {
    if (callSite instanceof PyCallExpression) {
      return ((PyCallExpression)callSite).multiResolveCallee(resolveContext);
    }
    else if (callSite instanceof PySubscriptionExpression) {
      return multiResolveCallee((PyReferenceOwner)callSite, resolveContext);
    }
    else {
      final List<PyCallableType> results = new ArrayList<>();

      for (PsiElement result : PyUtil.multiResolveTopPriority(callSite, resolveContext)) {
        if (result instanceof PyTypedElement) {
          final PyType resultType = resolveContext.getTypeEvalContext().getType((PyTypedElement)result);
          if (resultType instanceof PyCallableType) {
            results.add((PyCallableType)resultType);
            continue;
          }
        }
        return Collections.emptyList();
      }

      return results;
    }
  }
@NotNull
  private static List<@NotNull PyCallableType> multiResolveCalleeFunction(@NotNull PyCallSiteExpression callSite,
                                                                          @NotNull PyResolveContext resolveContext)