Skip to content

Commit 003c0a6

Browse files
Move normalization into services
1 parent 676983c commit 003c0a6

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/server/session.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -793,7 +793,7 @@ namespace ts.server {
793793
private getDocumentHighlights(args: protocol.DocumentHighlightsRequestArgs, simplifiedResult: boolean): ReadonlyArray<protocol.DocumentHighlightsItem> | ReadonlyArray<DocumentHighlights> {
794794
const { file, project } = this.getFileAndProject(args);
795795
const position = this.getPositionInFile(args, file);
796-
const documentHighlights = project.getLanguageService().getDocumentHighlights(file, position, map(args.filesToSearch, toNormalizedPath));
796+
const documentHighlights = project.getLanguageService().getDocumentHighlights(file, position, args.filesToSearch);
797797

798798
if (!documentHighlights) {
799799
return emptyArray;

src/services/services.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1673,6 +1673,7 @@ namespace ts {
16731673
}
16741674

16751675
function getDocumentHighlights(fileName: string, position: number, filesToSearch: ReadonlyArray<string>): DocumentHighlights[] {
1676+
filesToSearch = ts.map(filesToSearch, ts.normalizePath);
16761677
Debug.assert(contains(filesToSearch, fileName));
16771678
synchronizeHostData();
16781679
const sourceFilesToSearch = map(filesToSearch, f => Debug.assertDefined(program.getSourceFile(f)));

0 commit comments

Comments
 (0)