-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[flow] make autocompleteService_js return non-lazy result
Summary: The only difference between * `ServerProt.Response.Completion.completion_item` * `AutocompleteService_js.AcCompletion.completion_item` is that the former computes `documentation_and_tags` lazily. By the time `autocomplete_get_results` is done, we should have determined that final list of items that will be included in the response. It is safe at that point to force documentation and tags into evaluation without doing redundant work. In other words, the perf fix of D52670618 still applies. Motivation for this change is to allow be able to compare the result of completion between "typed-AST" and "on-demand" modes. To do so, I plan to use `eq` which cannot be expressed over lazy values. This also allows us to hide `AcCompletion` as an implementation detail of `AutocompleteService_js`. Changelog: [internal] Reviewed By: SamChou19815 Differential Revision: D55231178 fbshipit-source-id: 7c70c139a513a6645600c808c5998dfa1b267917
- Loading branch information
1 parent
bc4291c
commit 2488b95
Showing
3 changed files
with
22 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters