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

Add OrderedDict. Refactor Dict.render to utilize OrderedDict #116

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rainforest-bailey
Copy link

I would like to add a companion type to 'Dict', an 'OrderedDict', that will retain original ordering on keys.

@rainforest-bailey
Copy link
Author

For additional context on why this feature is useful. When generating code to initialize a struct, it is beneficial to be able to control the order in which fields are defined. I found myself comparing my code gen to an existing spec definition. Ideally, I would be able to visually scan the 2 side by side, but I had to search each field individually, which was more cumbersome.

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.

1 participant