提交 145e26ff 编写于 作者: A Allison Chou

Temporary workaround to report the last batch of results

上级 4b6b3f7a
...@@ -54,9 +54,13 @@ public FindAllReferencesHandler(IMetadataAsSourceFileService metadataAsSourceFil ...@@ -54,9 +54,13 @@ public FindAllReferencesHandler(IMetadataAsSourceFileService metadataAsSourceFil
// Finds the references for the symbol at the specific position in the document, reporting them via streaming to the LSP client. // Finds the references for the symbol at the specific position in the document, reporting them via streaming to the LSP client.
await findUsagesService.FindReferencesAsync(document, position, context).ConfigureAwait(false); await findUsagesService.FindReferencesAsync(document, position, context).ConfigureAwait(false);
await context.OnCompletedAsync().ConfigureAwait(false);
// This is a temporary workaround to report the last batch of results until an LSP bug is fixed:
// https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1094786/
Thread.Sleep(500);
// The results have already been reported to the client, so we don't need to return anything here. // The results have already been reported to the client, so we don't need to return anything here.
await context.OnCompletedAsync().ConfigureAwait(false);
return Array.Empty<LSP.VSReferenceItem>(); return Array.Empty<LSP.VSReferenceItem>();
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册