esprima icon indicating copy to clipboard operation
esprima copied to clipboard

ECMAScript parsing infrastructure for multipurpose analysis

Results 111 esprima issues
Sort by recently updated
recently updated
newest added

I think following line is not a valid TypeScript: https://github.com/jquery/esprima/blob/a971d877fe7af52d5518d25a758835dc51cd7dbe/src/nodes.ts#L632 I think a semicolon should be used instead: ```readonly regex: { pattern: string; flags: string }; ``` See [Object Types](https://github.com/microsoft/TypeScript/blob/master/doc/spec.md#1.3)....

**Steps to reproduce:** 1. Use Esprima demo page: https://esprima.org/demo/parse.html 2. Copy paste this code inside the editor ```javascript function a() { var b = 5; /* Comment1 */ } /*...

Multiple different Javascript snippets can result in a LineComment node: ```javascript // type1 type3 ``` From current Esprima's output there's no way to know which one of these 'styles' was...

super() in non derived class constructors should throw a syntax error ### Steps to reproduce ```js esprima.parse('class A{ constructor(){ super(); } }') ``` ### Expected output throw an syntax error....

As far as I know, only g, i , m, u, y are allowed as regular expression flags. Esprima allowes everything. ### Steps to reproduce ```js esprima.parse(`/(?:)/esprima_reg_exp_should_disallow_this`) ``` ### Expected...

### Steps to reproduce ```js esprima.parse('var AsyncGeneratorFunction = Object.getPrototypeOf(async function* () {}).constructor;') ``` ### Expected output A valid syntax tree. ### Actual output Error: Line 1: Unexpected token * ###...

hello,use this project in ES7,but not support decorator? ``` class OrderController { /** * @type methods */ @route() async submitOrder(ctx) { return await OrderService.submitOrder(ctx); }; } ``` report `Unexpected token...

New productions: TBD. AST format change: TBD. References: * The proposal: https://github.com/tc39/proposal-async-iteration * Change to the spec: * ESTree change:

stage3

### Steps to reproduce ```js es.parse('a\\u{0022}b=1') ``` ### Expected output pares error ### Actual output ```json { "type": "Program", "body": [ { "type": "ExpressionStatement", "expression": { "type": "AssignmentExpression", "operator": "=",...

When any get property is encountered the `context.allowYield` property is set to false and not reverted after parsing the getter body. This results in any future yield to be parsed...