Skip to content

Editorial: remove incorrect assertion in SerializeJSONProperty#3842

Open
bakkot wants to merge 1 commit intotc39:mainfrom
bakkot:rm-incorrect-assert
Open

Editorial: remove incorrect assertion in SerializeJSONProperty#3842
bakkot wants to merge 1 commit intotc39:mainfrom
bakkot:rm-incorrect-assert

Conversation

@bakkot
Copy link
Copy Markdown
Member

@bakkot bakkot commented May 1, 2026

Fixes a bad assert introduced in #3826. I suspect that assertion was added because a subsequent line passes the asserted-on value to SerializeJSONArray, which that PR thought took an Array; I've fixed that too.

I'm neutral between the narrow-but-not-really-helpful "an Array or a Proxy exotic object" (current state of this PR) vs just "an Object". I don't think it's worth spelling out "an Array or a Proxy for (possibly a Proxy for...) an Array".

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 1, 2026

The rendered spec preview for this PR is available as a single page at https://tc39.es/ecma262/pr/3842 and as multiple pages at https://tc39.es/ecma262/pr/3842/multipage .

@linusg
Copy link
Copy Markdown
Member

linusg commented May 1, 2026

I'm neutral between the narrow-but-not-really-helpful "an Array or a Proxy exotic object" (current state of this PR) vs just "an Object"

Mild preference for the former from me, though I agree either would be fine.

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.

3 participants