Skip to content

Can't parse top-level-await in call arguments #212

@fisker

Description

@fisker
> require('meriyah').version
'4.2.0'
> require('meriyah').parseModule('await 1')
{
  type: 'Program',
  sourceType: 'module',
  body: [ { type: 'ExpressionStatement', expression: [Object] } ]
}
> require('meriyah').parseModule('foo(await 1)')
Uncaught [ParseError [SyntaxError]: [1:9]: Await is only valid in async functions
] {
  index: 9,
  line: 1,
  column: 9,
  description: '[1:9]: Await is only valid in async functions',
  loc: { line: 1, column: 9 }
}

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions