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
Write a well-defined grammar #61
Comments
I decided to put my prototype on the Wiki. If you have any issues with that, please let me know. Thanks. |
This is great @jordanbtucker, thank you! No issues at all with it in the wiki. I do wonder if it could go in the repo itself though, since part of the purpose of this repo is to be the "spec". I don't feel strongly either way. WDYT? |
I think that might be a good idea, especially since I don't see a way to lock down Wiki pages. I'd like to expand the "spec" into a full document at some point. |
Already done 7 months ago. :) |
@rlidwka Nice document. Almost the same as the one on the wiki, as far as I can see, with a few differences: line terminators (#70), signed hexadecimals (#36), numeric literals as property names (#55), Unicode escapes in property names (#1), and it's one grammar instead of a lexical and a syntactical. |
Yeah, you see two different approaches here. This repository (and its grammar in wiki) is based on JSON parser. But in my implementation I actually got ES5 grammar and worked down from there, reducing features. So all the differences you see are probably differences between JSON and JavaScript that haven't been resolved yet. And a potential source of the confusion for users trying to use JS grammar with JSON5. |
Funny, that's the same thing I did when I started writing a JSON5 parser for another language. I used the ES5 grammar. That's when I started finding a lot of missing features. :) |
Offtopic: which language? Can we make a list of existing parsers somewhere? Do all tests pass? |
C# / .NET. It's a WIP at this point. I stopped to focus on JSON5 itself before continuing with other implementations. There's a page on the Wiki called In The Wild. I think that's a good starting point to keep that list. |
Just want to say that you guys are awesome. Thanks for all the great work! |
We now have an official spec in draft status. The PDF version can be found on the releases page. Ideally, discussions regarding the future of JSON5 will be discussed in the json5-spec repo, while discussions regarding the JavaScript reference implementation will still be discussed in this repo. I'd like to separate the goal of JSON5 from the different implementations. Let me know what you think. |
Nice @jordanbtucker. Question: should we (finally) just create a |
@aseemk That sounds good. I've got a partial C# implementation and another one for Go, but I haven't uploaded them yet. |
Thanks @jordanbtucker on creating the org! Happy to move this repo there. Should we keep the name simply |
I'm thinking |
Woohoo! Done. =) |
@aseemk Awesome. Thanks. BTW, did you see this controversial issue about removing support for |
I think JSON5 would benefit from a well-defined grammar like ECMAScript and JSON have. I wrote a prototype. The README is at the bottom.
The text was updated successfully, but these errors were encountered: