You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
await an expression that ends with at least two semicolons returns undefined #39932
changed the title [-]`undefined` is returned when an expression ends with more than one `;` with `await`[/-][+]`await` an expression that ends with at least two `;` returns `undefined`[/+]on Aug 29, 2021
changed the title [-]`await` an expression that ends with at least two `;` returns `undefined`[/-][+]`await` an expression that ends with at least two semicolons returns `undefined`[/+]on Aug 29, 2021
This seems normal, acorn returns an EmptyStatement for the extra(s) ;. I don't know if we should take the last ExpressionStatement before EmptyStatement(s) or keep this behavior. Knowing that in Firefox it returns the same result than Node.js (undefined) and in Chromium 1.
Activity
[-]`undefined` is returned when an expression ends with more than one `;` with `await`[/-][+]`await` an expression that ends with at least two `;` returns `undefined`[/+][-]`await` an expression that ends with at least two `;` returns `undefined`[/-][+]`await` an expression that ends with at least two semicolons returns `undefined`[/+]Mesteery commentedon Aug 29, 2021
This seems normal, acorn returns an EmptyStatement for the extra(s)
;. I don't know if we should take the last ExpressionStatement before EmptyStatement(s) or keep this behavior. Knowing that in Firefox it returns the same result than Node.js (undefined) and in Chromium1.repl: skip EmptyStatements and return result with TLA
repl: skip EmptyStatements and return result with TLA