Skip to content

BigInt literals, nullishCoalescing, numericSeparator breaks  #834

@radioman09

Description

@radioman09

Describe the bug
When passing code like
Input code

var foo =  2n + 7n;
//Error: internal error in Neon module: not implemented: compute_line_starts(char = '2')
var ano = { some: {
	ne:  {
		
	}
}};
var foo = ano.some.ne?.sdf?.snop;
const someValue = "test" ?? "default value";
//failed to parse module

Config

var transpiledJs = swc.transformSync(js, {
	minify: true,
	jsc: {
		parser: {
			nullishCoalescing: true,
			numericSeparator: true
		}
	}
});

Expected behavior
The code should transform and compile all code without errors.

Version
The version of @swc/core:
"@swc/core": "^1.1.56"

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions