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-94943: [Enum] improve repr() when inheriting from a dataclass #99740

Merged
merged 4 commits into from
Dec 6, 2022

Conversation

ethanfurman
Copy link
Member

@ethanfurman ethanfurman commented Nov 23, 2022

When inheriting from a dataclass, only show the field names in the value section of the member repr(), and not the dataclass' class name.

When inheriting from a dataclass, only show the field names in the value
section of the member repr(), and not the dataclass' class name.
@ethanfurman
Copy link
Member Author

Should probably have a way to keep a dataclass-generated repr.

@CAM-Gerlach CAM-Gerlach added type-feature A feature request or enhancement stdlib Python modules in the Lib dir 3.12 bugs and security fixes labels Nov 24, 2022
Copy link
Member

@CAM-Gerlach CAM-Gerlach left a comment

Choose a reason for hiding this comment

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

Just some relatively minor syntax and textual fixes, clarifications and refinements on the docs and NEWS entry, thanks.

Doc/howto/enum.rst Outdated Show resolved Hide resolved
Doc/library/enum.rst Outdated Show resolved Hide resolved
Doc/howto/enum.rst Outdated Show resolved Hide resolved
Doc/howto/enum.rst Show resolved Hide resolved
Doc/howto/enum.rst Outdated Show resolved Hide resolved
Lib/enum.py Outdated Show resolved Hide resolved
@ethanfurman ethanfurman merged commit 679efbb into python:main Dec 6, 2022
@ethanfurman ethanfurman deleted the enum-dataclass branch February 1, 2024 01:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.12 bugs and security fixes stdlib Python modules in the Lib dir type-feature A feature request or enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants