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

fix: upgrade acorn v8.11.3 #590

Merged
merged 3 commits into from
Jan 24, 2024
Merged

fix: upgrade acorn v8.11.3 #590

merged 3 commits into from
Jan 24, 2024

Conversation

aladdin-add
Copy link
Member

@aladdin-add aladdin-add commented Dec 29, 2023

the tests were updated:

@aladdin-add aladdin-add changed the title chore: upgrade acorn v8.11.2 chore: upgrade acorn v8.11.3 Jan 2, 2024
@aladdin-add
Copy link
Member Author

I've updated the tests and ignored some spacing/property ordering changes. hope it has a better readability. :)

@aladdin-add aladdin-add marked this pull request as ready for review January 2, 2024 10:25
@@ -183,7 +183,7 @@ export default {
]
},
{
"type": "Keyword",
"type": "Identifier",
"value": "default",
Copy link
Member

@nzakas nzakas Jan 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this another bug in Acorn?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think so, default is a reversed word in js. /cc @marijnh

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

filed in acorn: acornjs/acorn#1273

Copy link
Member Author

@aladdin-add aladdin-add Jan 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it was treated as a bugfix - as described in the linked issue. and I'm changing the PR title to "fix:".

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for following up on this. I'm not sure if we should treat this as a bug fix or a breaking change, or if we should modify Espree to output the "Keyword" as it did before. @mdjermanovic what do you think?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is default in export {foo as default} from "foo";?

In this context, default doesn't seem to have any particular syntactical meaning and is thus just a name like any other, so I think that "type": "Identifier" makes more sense than "type": "Keyword". Also, in the specification for Exports, it doesn't seem that default in this context appears as a terminal symbol (bolded) in any productions, which I think is a rule of thumb for whether something is a keyword or not.

I think we can classify this as a bug fix.

Copy link
Member

@nzakas nzakas Jan 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good. 👍

@nzakas
Copy link
Member

nzakas commented Jan 12, 2024

@aladdin-add where are we on this?

@aladdin-add aladdin-add marked this pull request as draft January 16, 2024 21:19
@aladdin-add aladdin-add marked this pull request as ready for review January 19, 2024 07:48
@aladdin-add aladdin-add changed the title chore: upgrade acorn v8.11.3 fix: upgrade acorn v8.11.3 Jan 19, 2024
Copy link
Member

@nzakas nzakas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@nzakas nzakas merged commit 6d30382 into main Jan 24, 2024
15 checks passed
@nzakas nzakas deleted the chore/upgrade-acorn-v8.11.2 branch January 24, 2024 17:48
@github-actions github-actions bot mentioned this pull request Jan 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants