Skip to content

Syntax Error for let var declaration under semicolon-less instantiation expressions #49348

@sosukesuzuki

Description

@sosukesuzuki

Bug Report

🔎 Search Terms

  • instantiation expression semicolon

🕗 Version & Regression Information

  • This is a bug of new syntax that is landed in TS 4.7

⏯ Playground Link

Playground link with relevant code

💻 Code

const foo = func<string>

let bar;

🙁 Actual behavior

Syntax error Cannot find name 'let'.(2304)

🙂 Expected behavior

Parsing successfully

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFix AvailableA PR has been opened for this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions