-
-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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
Add show_positions keyword argument to dis.dis and related functions
#123165
Labels
Comments
|
Since it's marked as an |
iritkatriel
pushed a commit
that referenced
this issue
Aug 21, 2024
blhsing
pushed a commit
to blhsing/cpython
that referenced
this issue
Aug 22, 2024
iritkatriel
pushed a commit
that referenced
this issue
Aug 22, 2024
iritkatriel
pushed a commit
that referenced
this issue
Sep 10, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels

Formed in 2009, the Archive Team (not to be confused with the archive.org Archive-It Team) is a rogue archivist collective dedicated to saving copies of rapidly dying or deleted websites for the sake of history and digital heritage. The group is 100% composed of volunteers and interested parties, and has expanded into a large amount of related projects for saving online and digital history.

Feature or enhancement
Proposal:
dis.disis a useful debugging tool when trying to debug minor bytecode compiler errors.However it lacks one important feature, the ability to see the exact positions attached to instructions. It can only show line numbers.
We should add a
show_positionskeyword argument to show positions.For example, the function:
disassembles to:
with
show_positionsit would disassemble to something like:Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
No response
Linked PRs
disfunctions render positions on demand #123168dis.dis(func, show_positions=True)#123220dis.disassemble#123808The text was updated successfully, but these errors were encountered: