Skip to content

Map parsing should automatically convert keys to strings #15

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

Open
nilium opened this issue Sep 29, 2018 · 0 comments
Open

Map parsing should automatically convert keys to strings #15

nilium opened this issue Sep 29, 2018 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest Hacktoberfest issues

Comments

@nilium
Copy link
Owner

nilium commented Sep 29, 2018

This'd be a convenience thing for maps, since as-is their keys must be -- syntactically -- strings right now. If non-string keys are encountered, the parser should convert them to strings where possible instead of treating them as an error.

This can't work in any obvious way for keys that are maps or arrays, but all other tokens should be usable (likely by transforming them into a bareword through their raw bytes). This poses a small question of whether a token's raw bytes must necessarily exist, but that seems like an easy 'yes' since it'll be necessary to keep those for tooling.

@nilium nilium added enhancement New feature or request good first issue Good for newcomers hacktoberfest Hacktoberfest issues labels Sep 29, 2018
@nilium nilium removed the hacktoberfest Hacktoberfest issues label Nov 2, 2018
@nilium nilium added the hacktoberfest Hacktoberfest issues label Oct 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest Hacktoberfest issues
Projects
Status: No status
Development

No branches or pull requests

1 participant