Skip to content
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

GH-111485: Factor out generation of uop IDs from cases generator. #112877

Merged
merged 7 commits into from Dec 11, 2023

Conversation

markshannon
Copy link
Member

@markshannon markshannon commented Dec 8, 2023

Tools/cases_generator/uop_id_generator.py Outdated Show resolved Hide resolved
Tools/cases_generator/uop_id_generator.py Outdated Show resolved Hide resolved
Tools/cases_generator/uop_id_generator.py Outdated Show resolved Hide resolved
Include/internal/pycore_uop_ids.h Show resolved Hide resolved
out.emit("#ifdef __cplusplus\n")
out.emit("}\n")
out.emit("#endif\n")
out.emit("#endif /* !Py_OPCODE_IDS_H */\n")
Copy link
Member

Choose a reason for hiding this comment

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

This postscript repeats itself in other generated files. Could be generated by a common utility function eventually. Or even a common context manager that adds the opening and closing bits.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, that makes sense for the header files.

@markshannon markshannon merged commit c27e9d5 into python:main Dec 11, 2023
36 checks passed
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.

None yet

3 participants