Resolve re-exports when looking for tslib helpers (#54317)

This commit is contained in:
Andrew Branch
2023-05-19 10:13:53 -07:00
committed by GitHub
parent ae33099f25
commit 2b7d517907
5 changed files with 107 additions and 1 deletions

View File

@@ -47033,7 +47033,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
if (requestedExternalEmitHelperNames.has(name)) continue;
requestedExternalEmitHelperNames.add(name);
const symbol = getSymbol(helpersModule.exports!, escapeLeadingUnderscores(name), SymbolFlags.Value);
const symbol = getSymbol(getExportsOfModule(helpersModule), escapeLeadingUnderscores(name), SymbolFlags.Value);
if (!symbol) {
error(location, Diagnostics.This_syntax_requires_an_imported_helper_named_1_which_does_not_exist_in_0_Consider_upgrading_your_version_of_0, externalHelpersModuleNameText, name);
}