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: support bigints in update expressions for private fields #14311

Merged
merged 2 commits into from Feb 27, 2022
Merged

fix: support bigints in update expressions for private fields #14311

merged 2 commits into from Feb 27, 2022

Conversation

magic-akari
Copy link
Contributor

@magic-akari magic-akari commented Feb 26, 2022

Q                       A
Fixed Issues? Fixes #14302
Patch: Bug Fix? 👍
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

Copy link
Contributor

@JLHwung JLHwung left a comment

Choose a reason for hiding this comment

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

Thanks!

@JLHwung JLHwung added PR: Bug Fix 🐛 A type of pull request used for our changelog categories Spec: Class Fields labels Feb 26, 2022
@@ -43,5 +43,19 @@ class Cl {

this.#privateFieldValue = -(this.#privateFieldValue ** this.#privateFieldValue);
this.publicFieldValue = -(this.publicFieldValue ** this.publicFieldValue);

this.#privateField = 0n;
Copy link
Member

Choose a reason for hiding this comment

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

Can you split this new test into a new one (updates-bigint) and add "minNodeVersion": "10.0.0" to its options.json file? Because older versions don't support bigints.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@nicolo-ribaudo nicolo-ribaudo changed the title fix: update expression for class private field fix: support bigints in update expressions for private fields Feb 27, 2022
@nicolo-ribaudo nicolo-ribaudo merged commit 7ff3084 into babel:main Feb 27, 2022
@magic-akari magic-akari deleted the fix/issue-14302 branch March 8, 2022 06:11
@github-actions github-actions bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Jun 8, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Bug Fix 🐛 A type of pull request used for our changelog categories Spec: Class Fields
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: update private field which is bigint would throw type error
3 participants