bpo-40257: Revert changes to inspect.getdoc() (GH-20073)

This commit is contained in:
Serhiy Storchaka 2020-05-18 20:25:07 +03:00 committed by GitHub
parent 98e42d1f88
commit 08b47c367a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 115 additions and 40 deletions

View file

@ -473,15 +473,12 @@ Retrieving source code
Get the documentation string for an object, cleaned up with :func:`cleandoc`.
If the documentation string for an object is not provided and the object is
a method, a property or a descriptor, retrieve the documentation
a class, a method, a property or a descriptor, retrieve the documentation
string from the inheritance hierarchy.
.. versionchanged:: 3.5
Documentation strings are now inherited if not overridden.
.. versionchanged:: 3.9
Documentation strings for classes are no longer inherited.
.. function:: getcomments(object)