From 7cad953b314473748a500f636213ff13039ae2e9 Mon Sep 17 00:00:00 2001 From: Serhiy Storchaka Date: Fri, 3 Apr 2015 22:38:53 +0300 Subject: Issue #15582: inspect.getdoc() now follows inheritance chains. --- Doc/library/inspect.rst | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Doc/library/inspect.rst') diff --git a/Doc/library/inspect.rst b/Doc/library/inspect.rst index 3d2132fd86..471200fa78 100644 --- a/Doc/library/inspect.rst +++ b/Doc/library/inspect.rst @@ -356,6 +356,9 @@ Retrieving source code .. function:: getdoc(object) 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 class, a method, a property or a descriptor, retrieve the documentation + string from the inheritance hierarchy. .. function:: getcomments(object) -- cgit v1.2.1