8000 bpo-38307: Add end_lineno attribute to pyclbr _Objects by kebab-mai-haddi · Pull Request #24348 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-38307: Add end_lineno attribute to pyclbr _Objects #24348

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from 1 commit
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
1f25ed4
compeltes the Stack implementation to yield ending line for each class.
Sep 28, 2019
7d2354a
reverts whitespace and unwanted changes including functions, comments…
Oct 6, 2019
c8a003d
removes leftover whitespace in b/w functions: unwanted
Oct 6, 2019
7e6f079
Initialize stack of (class, indent) pairs.
Feb 4, 2020
b7c1ce7
removes Stack() custom class and adds direct attribute (end_lineno) i…
Feb 4, 2020
3466f63
corrects the attribute name to end_lineno and sets the same without u…
Feb 8, 2020
f2a58c6
removes unwanted module: inspect
Feb 8, 2020
94edb5b
corrects the way of setting attribute
kebab-mai-haddi Feb 16, 2020
454d305
📜🤖 Added by blurb_it.
blurb-it[bot] Mar 16, 2020
dc0166f
wip: added end_lineno in tests
kebab-mai-haddi Mar 24, 2020
5a26a5c
Merge branch 'endline-in-readmodule-module' of github.com:avisrivasta…
kebab-mai-haddi Mar 24, 2020
ea2090b
wip
kebab-mai-haddi Aug 13, 2020
49d0695
compeltes the Stack implementation to yield ending line for each class.
Sep 28, 2019
33aa14c
reverts whitespace and unwanted changes including functions, comments…
Oct 6, 2019
2f9579a
removes leftover whitespace in b/w functions: unwanted
Oct 6, 2019
668fe22
wip: added end_lineno in tests
kebab-mai-haddi Mar 24, 2020
efb49ea
📜🤖 Added by blurb_it.
blurb-it[bot] Mar 16, 2020
963b783
wip
kebab-mai-haddi Aug 13, 2020
d0d0966
fixed conflicts after diver 8000 ge
kebab-mai-haddi Jan 27, 2021
d924d4a
adds end_lineno as an attribute for Class and Functions objects
kebab-mai-haddi Jan 27, 2021
78f166f
adds the news.
kebab-mai-haddi Jan 27, 2021
fc74ec7
adds positional arguments in the tests and end_lineno as an argument …
kebab-mai-haddi Jan 27, 2021
b5f29c0
removes debugging print statements.
kebab-mai-haddi Jan 27, 2021
f3c09fe
adds endline no in all the tests for the dummy tree"
kebab-mai-haddi Jan 27, 2021
7337551
adds endline no in all the tests for the dummy tree
kebab-mai-haddi Jan 27, 2021
3e8181c
Merge branch 'endline-in-readmodule-module' of github.com:kebab-mai-h…
kebab-mai-haddi Jan 27, 2021
77784e3
Update 2020-03-16-03-03-21.bpo-38307.2cmw2i.rst
terryjreedy Jan 27, 2021
d73395a
Update 2020-03-16-03-03-21.bpo-38307.2cmw2i.rst
terryjreedy Jan 27, 2021
cc82d4f
Merge remote-tracking branch 'upstream/master' into pr_24348
terryjreedy Feb 1, 2021
9238fcd
Fix end_lineno.
terryjreedy Feb 1, 2021
ed20fa4
Add What's New in 3.10 entry
terryjreedy Feb 1, 2021
48b7341
Update Doc/whatsnew/3.10.rst
terryjreedy Feb 1, 2021
9172efc
Direct calls by by keyword
terryjreedy Feb 1, 2021
d0ca986
blank line
terryjreedy Feb 1, 2021
af31c28
Merge branch 'endline-in-readmodule-module' of https://github.com/keb…
terryjreedy Feb 1, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
removes leftover whitespace in b/w functions: unwanted
  • Loading branch information
Aviral Srivastava authored and kebab-mai-haddi committed Jan 27, 2021
commit 2f9579af2cf6dcc728e896688a37223795f09dce
4 changes: 0 additions & 4 deletions Lib/pyclbr.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,10 @@ def _nest_function(ob, func_name, lineno, is_async=False):
"Return a Function after nesting within ob."
return Function(ob.module, func_name, ob.file, lineno, ob, is_async)


def _nest_class(ob, class_name, lineno, super=None):
"Return a Class after nesting within ob."
return Class(ob.module, class_name, super, ob.file, lineno, ob)


def readmodule(module, path=None):
"""Return Class objects for the top-level classes in module.

Expand All @@ -101,7 +99,6 @@ def readmodule(module, path=None):
res[key] = value
return res


def readmodule_ex(module, path=None):
"""Return a dictionary with all functions and classes in module.

Expand All @@ -111,7 +108,6 @@ def readmodule_ex(module, path=None):
"""
return _readmodule(module, path or [])


def _readmodule(module, path, inpackage=None):
"""Do the hard work for readmodule[_ex].

Expand Down
0