MCPcopy Index your code
hub / github.com/python/cpython / is_related

Function is_related

Lib/functools.py:837–840  ·  view source on GitHub ↗
(typ)

Source from the content-addressed store, hash-verified

835 bases = set(cls.__mro__)
836 # Remove entries which are already present in the __mro__ or unrelated.
837 def is_related(typ):
838 return (typ not in bases and hasattr(typ, '__mro__')
839 and not isinstance(typ, GenericAlias)
840 and issubclass(cls, typ))
841 types = [n for n in types if is_related(n)]
842 # Remove entries which are strict bases of other entries (they will end up
843 # in the MRO anyway.

Callers 1

_compose_mroFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…