Fixed TypeScript.declarationEmitGetAccessorFunctionTime having a wrong value

This commit is contained in:
Dick van den Brink 2014-08-21 21:27:30 +02:00
parent cbf4edabe1
commit 606601bc7c

View file

@ -763,7 +763,7 @@ module TypeScript {
var start = new Date().getTime();
var accessors = PullHelpers.getGetterAndSetterFunction(funcDecl, this.semanticInfoChain);
TypeScript.declarationEmitGetAccessorFunctionTime += new Date().getTime();
TypeScript.declarationEmitGetAccessorFunctionTime += new Date().getTime() - start;
var comments: Comment[] = [];
if (accessors.getter) {
@ -787,7 +787,7 @@ module TypeScript {
private emitMemberAccessorDeclaration(funcDecl: ISyntaxElement, modifiers: ISyntaxToken[], name: ISyntaxToken) {
var start = new Date().getTime();
var accessorSymbol = PullHelpers.getAccessorSymbol(funcDecl, this.semanticInfoChain);
TypeScript.declarationEmitGetAccessorFunctionTime += new Date().getTime();
TypeScript.declarationEmitGetAccessorFunctionTime += new Date().getTime() - start;
if (funcDecl.kind() === SyntaxKind.SetAccessor && accessorSymbol.getGetter()) {
// Setter is being used to emit the type info.