From 1fe19136d767ad2e00a6d47a7af16408ad8ac0de Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 8 Dec 2014 13:00:46 -0800 Subject: [PATCH] Remove unused parameter to getCompletionsAtPosition Conflicts: tests/baselines/reference/APISample_node_compile.js tests/baselines/reference/APISample_node_compile.types tests/baselines/reference/APISample_standalone_compile.js tests/baselines/reference/APISample_standalone_compile.types --- src/harness/fourslash.ts | 6 +++--- src/services/services.ts | 6 +++--- src/services/shims.ts | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index da13735872d68..e523def8be204 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -750,11 +750,11 @@ module FourSlash { } private getMemberListAtCaret() { - return this.languageService.getCompletionsAtPosition(this.activeFile.fileName, this.currentCaretPosition, true); + return this.languageService.getCompletionsAtPosition(this.activeFile.fileName, this.currentCaretPosition); } private getCompletionListAtCaret() { - return this.languageService.getCompletionsAtPosition(this.activeFile.fileName, this.currentCaretPosition, false); + return this.languageService.getCompletionsAtPosition(this.activeFile.fileName, this.currentCaretPosition); } private getCompletionEntryDetails(entryName: string) { @@ -1364,7 +1364,7 @@ module FourSlash { this.languageService.getSignatureHelpItems(this.activeFile.fileName, offset); } else if (prevChar === ' ' && /A-Za-z_/.test(ch)) { /* Completions */ - this.languageService.getCompletionsAtPosition(this.activeFile.fileName, offset, false); + this.languageService.getCompletionsAtPosition(this.activeFile.fileName, offset); } if (i % errorCadence === 0) { diff --git a/src/services/services.ts b/src/services/services.ts index 86577da8fbddf..66108bb29bb77 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -914,7 +914,7 @@ module ts { getSyntacticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[]; getSemanticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[]; - getCompletionsAtPosition(fileName: string, position: number, isMemberCompletion: boolean): CompletionInfo; + getCompletionsAtPosition(fileName: string, position: number): CompletionInfo; getCompletionEntryDetails(fileName: string, position: number, entryName: string): CompletionEntryDetails; getQuickInfoAtPosition(fileName: string, position: number): QuickInfo; @@ -2669,7 +2669,7 @@ module ts { }; } - function getCompletionsAtPosition(filename: string, position: number, isMemberCompletion: boolean) { + function getCompletionsAtPosition(filename: string, position: number) { synchronizeHostData(); filename = normalizeSlashes(filename); @@ -2744,7 +2744,7 @@ module ts { if (isRightOfDot) { // Right of dot member completion list var symbols: Symbol[] = []; - isMemberCompletion = true; + var isMemberCompletion = true; if (node.kind === SyntaxKind.Identifier || node.kind === SyntaxKind.QualifiedName || node.kind === SyntaxKind.PropertyAccessExpression) { var symbol = typeInfoResolver.getSymbolAtLocation(node); diff --git a/src/services/shims.ts b/src/services/shims.ts index d139381c225c2..dfec12d0f795c 100644 --- a/src/services/shims.ts +++ b/src/services/shims.ts @@ -88,7 +88,7 @@ module ts { getSyntacticClassifications(fileName: string, start: number, length: number): string; - getCompletionsAtPosition(fileName: string, position: number, isMemberCompletion: boolean): string; + getCompletionsAtPosition(fileName: string, position: number): string; getCompletionEntryDetails(fileName: string, position: number, entryName: string): string; getQuickInfoAtPosition(fileName: string, position: number): string; @@ -694,11 +694,11 @@ module ts { * to provide at the given source position and providing a member completion * list if requested. */ - public getCompletionsAtPosition(fileName: string, position: number, isMemberCompletion: boolean) { + public getCompletionsAtPosition(fileName: string, position: number) { return this.forwardJSONCall( - "getCompletionsAtPosition('" + fileName + "', " + position + ", " + isMemberCompletion + ")", + "getCompletionsAtPosition('" + fileName + "', " + position + ")", () => { - var completion = this.languageService.getCompletionsAtPosition(fileName, position, isMemberCompletion); + var completion = this.languageService.getCompletionsAtPosition(fileName, position); return completion; }); }