-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Editorial: Extract JSON parsing into its own AO #3540
base: main
Are you sure you want to change the base?
Conversation
<dl class="header"> | ||
</dl> | ||
<emu-alg> | ||
1. [id="step-json-parse-validate"] If StringToCodePoints(_text_) is not a valid JSON text as specified in ECMA-404, throw a *SyntaxError* exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to reword this step otherwise ecmarkup was complaining that this AO can never return an abrupt completion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's arguably a bug in ecmarkup, but I like this wording better anyway.
spec.html
Outdated
<p>It is not permitted for a conforming implementation of `JSON.parse` to extend the JSON grammars. If an implementation wishes to support a modified or extended JSON interchange format it must do so by defining a different parse function.</p> | ||
<emu-note> | ||
<p>In the case where there are duplicate name Strings within an object, lexically preceding values for the same key shall be overwritten.</p> | ||
</emu-note> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved these two sentences from InternalizeJSONProperty to here, since they didn't really make sense there.
76fb39b
to
e355de5
Compare
Ref #3538 / #3391 (comment). I'm also going to use this AO in ECMA-426.