List<PyFunction> (@NotNull PyClass pyClass, @NotNull TypeEvalContext context) { final Map<String, PyFunction> functions = Maps.newLinkedHashMap(); for (final PyClassLikeType type : pyClass.getAncestorTypes(context)) { if (type != null) { for (PyFunction function : PyTypeUtil.getMembersOfType(type, PyFunction.class, false, context)) { final String name = function.getName(); if (name != null) { if (!functions.containsKey(name) || PyiUtil.isOverload(functions.get(name), context) && !PyiUtil.isOverload(function, context)) { functions.put(name, function); } } } } } return Lists.newArrayList(functions.values()); }