Skip to content

BigInt shouldn't be considered experimental #28456

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

Merged
merged 8 commits into from
Nov 12, 2018

Conversation

DanielRosenwasser
Copy link
Member

I know that in #25886 we discussed that we should gate the functionality behind a flag, but we have a degree of confidence that the BigInt proposal is relatively stable.

  • Chrome ships it in stable releases.
  • Node 11 ships with it now too

Additionally, we haven't hidden features like object rest/spread behind a flag, even when that feature had no browser implementations, so it's not clear why we need it here.

@DanielRosenwasser
Copy link
Member Author

CC @bterlson @RyanCavanaugh @calebsander for thoughts

@calebsander
Copy link
Contributor

I would agree that BigInt is not really "experimental"—V8 acts as a well-defined reference implementation. I would add that BigInt literals and libs were available in Node 10 (which has been out for 6 months), not just Node 11. Forcing the user to target esnext seems like enough of a barrier to check that they really want to use features without universal support. Thanks for fixing my spelling mistake too 😄

@sheetalkamat
Copy link
Member

ok. You need to update baselines and also remove experimentalBigInt from bunch of test cases

const bigintNumber = 123n * 0b1111n + 0o444n * 0x7fn; // each literal should error

Copy link
Contributor

Choose a reason for hiding this comment

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

I think you added 2 newlines here, but probably only meant to add 1

var bigintType; // should not error
var bigintLiteralType; // should not error when used as type
var bigintNegativeLiteralType; // should not error when used as type
var bigintNumber = 123n * 15n + 292n * 0x7fn; // each literal should error
Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't these warnExperimentalBigIntLiteral.* baselines be removed?

Copy link
Contributor

Choose a reason for hiding this comment

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

You removed warnExperimentalBigIntLiteral.errors.txt but not the .js, the .symbols, and the .types files

@DanielRosenwasser DanielRosenwasser merged commit 25462be into master Nov 12, 2018
@DanielRosenwasser DanielRosenwasser deleted the nonExperimentalBigInt branch November 12, 2018 23:59
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