Skip to content

transformer: typescript syntax inside SimpleAssignmentTarget is not stripped #4870

@Boshen

Description

@Boshen
pub enum SimpleAssignmentTarget<'a> {
    AssignmentTargetIdentifier(Box<'a, IdentifierReference<'a>>) = 0,
    TSAsExpression(Box<'a, TSAsExpression<'a>>) = 1,
    TSSatisfiesExpression(Box<'a, TSSatisfiesExpression<'a>>) = 2,
    TSNonNullExpression(Box<'a, TSNonNullExpression<'a>>) = 3,
    TSTypeAssertion(Box<'a, TSTypeAssertion<'a>>) = 4,
    TSInstantiationExpression(Box<'a, TSInstantiationExpression<'a>>) = 5,
    // `MemberExpression` variants added here by `inherit_variants!` macro
    @inherit MemberExpression
}

There is not Expression here, it's not covered in the transformer visiter.

Test case would be for example x!++.

or transformer typescript case:

Mismatch: "compiler/incrementOnNullAssertion.ts"

Metadata

Metadata

Assignees

Labels

C-bugCategory - Bug

Type

No type

Priority

None yet

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions