Skip to content

gh-91428: Add _PyOpcode_OpName to opcode.h of debug builds - #91430

Merged
sweeneyde merged 5 commits into
python:mainfrom
sweeneyde:opname
Apr 11, 2022
Merged

gh-91428: Add _PyOpcode_OpName to opcode.h of debug builds#91430
sweeneyde merged 5 commits into
python:mainfrom
sweeneyde:opname

Conversation

@sweeneyde

@sweeneyde sweeneyde commented Apr 10, 2022

Copy link
Copy Markdown
Member

@sweeneyde
sweeneyde requested a review from brandtbucher April 11, 2022 16:57

@brandtbucher brandtbucher left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome, thanks.

One minor suggestion (makes it a bit easier to spot mistakes):

Comment thread Tools/scripts/generate_opcode_h.py Outdated
Comment on lines +114 to +115
for name, op in opmap.items():
fobj.write(f''' [{op}] = "{name}",\n''')

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
for name, op in opmap.items():
fobj.write(f''' [{op}] = "{name}",\n''')
for name in opmap:
fobj.write(f''' [{name}] = "{name}",\n''')

@sweeneyde
sweeneyde merged commit 8a35ce3 into python:main Apr 11, 2022
@sweeneyde
sweeneyde deleted the opname branch April 12, 2022 00:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants