-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Open
Labels
BugA bug in TypeScriptA bug in TypeScriptCrashFor flagging bugs which are compiler or service crashes or unclean exits, rather than bad outputFor flagging bugs which are compiler or service crashes or unclean exits, rather than bad outputDomain: Node ESMLike ES Modules, but specific to Node.js support (cts, cts, mjs, mts)Like ES Modules, but specific to Node.js support (cts, cts, mjs, mts)Help WantedYou can do thisYou can do this
Milestone
Description
Bug Report
🔎 Search Terms
unhandled type any
💻 Code
// @module: nodenext
// @allowJs: true
// @noEmit: true
// @Filename: single-null-export.js
module.exports = null;
// @Filename: index.mts
import * as x from "./single-null-export.js";🙁 Actual behavior
Error: Debug Failure. Unhandled type Any
at resolveStructuredTypeMembers (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:53313:15)
at cloneTypeAsModuleType (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:45963:32)
at resolveESModuleSymbol (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:45942:20)
at getTargetOfNamespaceImport (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:44942:22)
at getTargetOfAliasDeclaration (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:45249:16)
at resolveAlias (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:45295:22)
at checkAliasSymbol (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:78629:20)
at checkImportBinding (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:78745:5)
at checkImportDeclaration (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:78794:13)
at checkSourceElementWorker (/Users/andrew/Developer/microsoft/eg/crash/node_modules/typescript/lib/tsc.js:79280:16)
🙂 Expected behavior
Compiles without error (and the type of x should be something like { default: null })
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptCrashFor flagging bugs which are compiler or service crashes or unclean exits, rather than bad outputFor flagging bugs which are compiler or service crashes or unclean exits, rather than bad outputDomain: Node ESMLike ES Modules, but specific to Node.js support (cts, cts, mjs, mts)Like ES Modules, but specific to Node.js support (cts, cts, mjs, mts)Help WantedYou can do thisYou can do this