diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2024-05-06 12:02:37 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-06 12:02:37 +0300 |
commit | 153b3f75306b5d26e29ea157105d0fdc247ef853 (patch) | |
tree | f73ede56af175d27698ef56bec21073f98889bbc /Lib/pydoc.py | |
parent | 716ec4bfcf1a564db9936122c442baa99f9c4a8c (diff) | |
download | cpython-153b3f75306b5d26e29ea157105d0fdc247ef853.tar.gz cpython-153b3f75306b5d26e29ea157105d0fdc247ef853.zip |
gh-118465: Add __firstlineno__ attribute to class (GH-118475)
It is set by compiler with the line number of the first line of
the class definition.
Diffstat (limited to 'Lib/pydoc.py')
-rwxr-xr-x | Lib/pydoc.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py index eaaf8249b20..55ccf2152c2 100755 --- a/Lib/pydoc.py +++ b/Lib/pydoc.py @@ -326,7 +326,7 @@ def visiblename(name, all=None, obj=None): '__date__', '__doc__', '__file__', '__spec__', '__loader__', '__module__', '__name__', '__package__', '__path__', '__qualname__', '__slots__', '__version__', - '__static_attributes__'}: + '__static_attributes__', '__firstlineno__'}: return 0 # Private names are hidden, but special names are displayed. if name.startswith('__') and name.endswith('__'): return 1 |