Skip to content

Commit 766cb68

Browse files
committed
Add comments
1 parent 1932f72 commit 766cb68

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/compiler/checker.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10982,6 +10982,8 @@ module ts {
1098210982
function getExportNameSubstitution(symbol: Symbol, location: Node): string {
1098310983
if (isExternalModuleSymbol(symbol.parent)) {
1098410984
var symbolName = unescapeIdentifier(symbol.name);
10985+
// If this is es6 or higher, just use the name of the export
10986+
// no need to qualify it.
1098510987
if (languageVersion >= ScriptTarget.ES6) {
1098610988
return symbolName;
1098710989
}

src/compiler/emitter.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4903,6 +4903,7 @@ module ts {
49034903
}
49044904

49054905
write("class ");
4906+
// check if this is an "export default class" as it may not have a name
49064907
if (node.name || !(node.flags & NodeFlags.Default)) {
49074908
emitDeclarationName(node);
49084909
}

0 commit comments

Comments
 (0)