Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Incosistent AST for typeArgument and typeParameters #220

Closed
Labels
package: typescript-estreeIssues related to @typescript-eslint/typescript-estree
@armano2

Description

@armano2

While doing#219 i notice that we have small inconsistency in AST, sometimes we are outputtingTSTypeParameterDeclaration andTSTypeParameterInstantiation without nodes and sometimes we are omitting this node completely.

if(superClass.types[0]&&superClass.types[0].typeArguments){
result.superTypeParameters=this.convertTypeArgumentsToTypeParameters(
superClass.types[0].typeArguments
);
}

if(node.typeArguments&&node.typeArguments.length){
result.typeParameters=this.convertTypeArgumentsToTypeParameters(
node.typeArguments
);
}

if(node.typeParameters&&node.typeParameters.length){
result.typeParameters=this.convertTSTypeParametersToTypeParametersDeclaration(
node.typeParameters
);
}

if(node.typeParameters){
result.typeParameters=this.convertTSTypeParametersToTypeParametersDeclaration(
node.typeParameters
);
}

we should align it, but i'm unsure if we should always have it or not

additionally we should handle#146 in update for it

Metadata

Metadata

Assignees

No one assigned

    Labels

    package: typescript-estreeIssues related to @typescript-eslint/typescript-estree

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp