Skip to content

Conform bigint literals to the new ESTree spec #1999

Closed
@bradzacher

Description

@bradzacher

For this code example:

const x = 1n;

We currently emit the following AST (excluding the variable decl):

{
  "type": "BigIntLiteral",
  "raw": "1n",
  "value": "1",
}

When we should be emitting this (as per the ESTree spec

{
  "type": "Literal",
  "raw": "1n",
  "value": 1n,
  "bigint": "1"
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    breaking changeThis change will require a new major version to be releasedenhancementNew feature or requestpackage: typescript-estreeIssues related to @typescript-eslint/typescript-estree

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions