Show More
@@ -766,21 +766,22 b' class Inspector(Colorable):' | |||||
766 | if inspect.isclass(obj): |
|
766 | if inspect.isclass(obj): | |
767 | out['isclass'] = True |
|
767 | out['isclass'] = True | |
768 |
|
768 | |||
769 |
# get the |
|
769 | # get the init signature: | |
770 | try: |
|
770 | try: | |
771 | init_def = self._getdef(obj, oname) |
|
771 | init_def = self._getdef(obj, oname) | |
772 | except AttributeError: |
|
772 | except AttributeError: | |
773 | init_def = None |
|
773 | init_def = None | |
774 | else: |
|
774 | ||
|
775 | if init_def: | |||
775 | out['init_definition'] = self.format(init_def) |
|
776 | out['init_definition'] = self.format(init_def) | |
776 |
|
777 | |||
777 | # get the __init__ docstring |
|
778 | # get the __init__ docstring | |
778 | try: |
|
779 | try: | |
779 | obj_init = obj.__init__ |
|
780 | obj_init = obj.__init__ | |
780 | except AttributeError: |
|
781 | except AttributeError: | |
781 |
|
|
782 | init_ds = None | |
782 | else: |
|
783 | else: | |
783 |
init_ds |
|
784 | init_ds = getdoc(obj_init) | |
784 | # Skip Python's auto-generated docstrings |
|
785 | # Skip Python's auto-generated docstrings | |
785 | if init_ds == _object_init_docstring: |
|
786 | if init_ds == _object_init_docstring: | |
786 | init_ds = None |
|
787 | init_ds = None |
General Comments 0
You need to be logged in to leave comments.
Login now