FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-105481: reduce repetition in opcode metadata generation code by iritkatriel · Pull Request #107942 · python/cpython · GitHub

/ cpython Public

gh-105481: reduce repetition in opcode metadata generation code - #107942

Merged
iritkatriel merged 2 commits into
python:mainfrom
iritkatriel:metadata
Aug 14, 2023
Merged

gh-105481: reduce repetition in opcode metadata generation code#107942
iritkatriel merged 2 commits into
python:mainfrom
iritkatriel:metadata

Conversation

iritkatriel commented Aug 14, 2023
edited by bedevere-bot
Loading

Copy link
Copy Markdown
Member

This will simplify adding more stuff to the metadata.

gvanrossum 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.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Optional suggestion.

Comment thread Tools/cases_generator/generate_cases.py Outdated
with self.metadata_item(
f"int _PyOpcode_num_{direction}(int opcode, int oparg, bool jump)", "", ""
):
self.out.emit(" switch(opcode) {")

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.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

You could use ‘with self.out.block()’ and indent() here instead of adding spaces to the statements.

iritkatriel enabled auto-merge (squash) August 14, 2023 18:03
iritkatriel merged commit 3974534 into python:main Aug 14, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL