You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.rst
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -75,6 +75,7 @@ What's New?
75
75
76
76
in development
77
77
^^^^^^^^^^^^^^
78
+
* Fix long standing bugs in ``Class`` method resolution order.
78
79
* Improve the extensibility of pydoctor (`more infos on extensions <https://pydoctor.readthedocs.io/en/latest/customize.html#use-a-custom-system-class>`_)
79
80
* Fix line numbers in reStructuredText xref warnings.
80
81
* Add support for `twisted.python.deprecated` (this was originally part of Twisted's customizations).
@note: The actual correct value is only set in post-processing, if L{mro()} is called
584
+
in the AST visitors, it will return the same as C{list(self.allbases(include_self))}.
585
+
"""
586
+
ifself._mroisNone:
587
+
returnlist(self.allbases(include_self))
588
+
589
+
_mro: List[Union[str, Class]]
590
+
ifinclude_externalisFalse:
591
+
_mro= [oforoinself._mroifnotisinstance(o, str)]
592
+
else:
593
+
_mro=self._mro
594
+
ifinclude_selfisFalse:
595
+
_mro=_mro[1:]
596
+
return_mro
597
+
598
+
@property
599
+
defbases(self) ->List[str]:
600
+
"""
601
+
Fully qualified names of the bases of this class.
602
+
"""
603
+
returnself._finalbasesif \
604
+
self._finalbasesisnotNoneelseself._initialbases
605
+
606
+
@property
607
+
defbaseobjects(self) ->List[Optional['Class']]:
608
+
"""
609
+
Base objects, L{None} value is inserted when the base class could not be found in the system.
610
+
611
+
@note: This property is currently computed two times, a first time when we're visiting the ClassDef and initially creating the object.
612
+
It's computed another time in post-processing to try to resolve the names that could not be resolved the first time. This is needed when there are import cycles.
613
+
614
+
Meaning depending on the state of the system, this property can return either the initial objects or the final objects
0 commit comments