Skip to content

Commit 62fb5e8

Browse files
author
Yui T
committed
Include debug assert
1 parent c5a2969 commit 62fb5e8

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/services/services.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1901,7 +1901,7 @@ namespace ts {
19011901
sourceMapText = text;
19021902
}
19031903
else {
1904-
Debug.assert(outputText === undefined, "Unexpected multiple outputs for the file: " + name);
1904+
Debug.assert(outputText === undefined, `Unexpected multiple outputs for the file: '${name}'`);
19051905
outputText = text;
19061906
}
19071907
},
@@ -4248,7 +4248,8 @@ namespace ts {
42484248
else {
42494249
// Method/function type parameter
42504250
let declaration = <Node>getDeclarationOfKind(symbol, SyntaxKind.TypeParameter);
4251-
declaration = declaration ? declaration.parent : undefined;
4251+
Debug.assert(declaration !== undefined);
4252+
declaration = declaration.parent;
42524253

42534254
if (declaration) {
42544255
if (isFunctionLikeKind(declaration.kind)) {

0 commit comments

Comments
 (0)