Skip to content

Typo in function emitExternalImportDeclaration? #10505

@kzc

Description

@kzc
const isNakedImport = SyntaxKind.ImportDeclaration && !(<ImportDeclaration>node).importClause;

https://github.com/Microsoft/TypeScript/blob/ddb5a00410d695d35b55c5482876a16f7c696c4b/src/compiler/emitter.ts#L6590

Possibly missing node.kind === before SyntaxKind.ImportDeclaration ?

Noticed it when running uglifyjs lib/tsc.js -c

WARN: Condition left of && always true [lib/tsc.js:34409,48]
 34409                              var isNakedImport = 230 && !node.importClause;

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptFixedA PR has been merged for this issueHelp WantedYou can do this

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions