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

Support listing enums in specified order #274

Merged
merged 2 commits into from Feb 21, 2022
Merged

Support listing enums in specified order #274

merged 2 commits into from Feb 21, 2022

Conversation

aliereno
Copy link
Contributor

@aliereno aliereno commented Feb 20, 2022

Hi, I saw the issue and wanted to contribute. I am new to this codebase, I am sorry if I missed something.

Closes #230

@alecthomas
Copy link
Owner

alecthomas commented Feb 20, 2022

I don't think this will solve #230. The enum values are stored in a map, so this will just result in whatever the map order happens to be. I think it would be better to just store them in a slice instead, and not sort them by default, as the ordering is just a side-effect of being in a map.

@alecthomas
Copy link
Owner

alecthomas commented Feb 21, 2022

Nice!

@alecthomas alecthomas merged commit cc81f03 into alecthomas:master Feb 21, 2022
2 checks passed
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.

2 participants