private static boolean isAbstractMethodForClass(@NotNull PyFunction method, @NotNull PyClass cls, @NotNull TypeEvalContext context) {
    final String methodName = method.getName();
    if (methodName == null ||
        cls.findMethodByName(methodName, false, context) != null ||
        cls.findClassAttribute(methodName, false, context) != null) {
      return false;
    }
    final PyClass methodClass = method.getContainingClass();
    if (methodClass != null) {
      for (PyClass ancestor : cls.getAncestorClasses(context)) {
        if (ancestor.equals(methodClass)) break;
        if (ancestor.findClassAttribute(methodName, false, context) != null) return false;
      }
    }
    return method.onlyRaisesNotImplementedError() || PyKnownDecoratorUtil.hasAbstractDecorator(method, context);
  }
private static boolean isAbstractMethodForClass(@NotNull PyFunction method, @NotNull PyClass cls, @NotNull TypeEvalContext context)