Skip to content

Incorrect emit for IIFE with assertion in property access in call expression #18668

Closed
@DanielRosenwasser

Description

@DanielRosenwasser

Input

(function a() { } as any)().foo()

Expected

(function a() { }().foo)();

Actual

function a() { }().foo();

Notice that this produces an un-parenthesized function expression.

Potentially addressable by work in #18300.

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFixedA PR has been merged for this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions