Remove unused property 'referencedDiagnostics' (#23688)

This commit is contained in:
Andy 2018-04-25 15:24:36 -07:00 committed by GitHub
parent b2bfccfce4
commit 4dc4b8d777
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 7 deletions

View File

@ -304,14 +304,13 @@ namespace Utils {
o.containsParseError = true;
}
ts.forEach(Object.getOwnPropertyNames(n), propertyName => {
for (const propertyName of Object.getOwnPropertyNames(n) as ReadonlyArray<keyof ts.SourceFile | keyof ts.Identifier>) {
switch (propertyName) {
case "parent":
case "symbol":
case "locals":
case "localSymbol":
case "kind":
case "semanticDiagnostics":
case "id":
case "nodeCount":
case "symbolCount":
@ -334,7 +333,6 @@ namespace Utils {
}
break;
case "referenceDiagnostics":
case "parseDiagnostics":
o[propertyName] = convertDiagnostics((<any>n)[propertyName]);
break;
@ -355,9 +353,7 @@ namespace Utils {
default:
o[propertyName] = (<any>n)[propertyName];
}
return undefined;
});
}
return o;
}

View File

@ -546,7 +546,6 @@ namespace ts {
public typeReferenceDirectives: FileReference[];
public syntacticDiagnostics: Diagnostic[];
public referenceDiagnostics: Diagnostic[];
public parseDiagnostics: Diagnostic[];
public bindDiagnostics: Diagnostic[];