-
-
Notifications
You must be signed in to change notification settings - Fork 130
refactor(web): simple reuse of search modules 🚂 #14921
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
jahorton
wants to merge
1
commit into
refactor/web/relocate-search-space
Choose a base branch
from
refactor/web/simple-search-space-reuse
base: refactor/web/relocate-search-space
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
refactor(web): simple reuse of search modules 🚂 #14921
jahorton
wants to merge
1
commit into
refactor/web/relocate-search-space
from
refactor/web/simple-search-space-reuse
+151
−136
Conversation
This file contains hidden or 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
User Test ResultsTest specification and instructions User tests are not required Test Artifacts
|
db32a59 to
be473a1
Compare
1eaf922 to
ddf9a58
Compare
This changes SearchQuotientSpur to construct new instances whenever the path is extended, treating SearchQuotientSpur as an immutable portion of the search graph that may be extended by new input, creating new instances of SearchQuotientSpur. This, in turn, removes the need to clone SearchQuotientSpur instances when new input is received for an incoming token; the original instance's represention will remain unchanged and may also be reused by a new instance extending the graph for the newly-received input. Relates-to: #14445 Build-bot: skip build:web Test-bot: skip
6ecc09a to
4b20187
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This changes SearchQuotientSpur, our predecessor to module-based search-graph management, to construct new instances whenever the path is extended, treating SearchQuotientSpur as an immutable portion of the search graph that may be referenced by path extensions - new instances of SearchQuotientSpur. No inputs may be added into pre-existing instances (the previous pattern) - instead, adding an input creates a new instance that references and utilizes the old one without editing what it represents.
This, in turn, removes the need to clone SearchQuotientSpur instances when new input is received for an incoming token.
Relates-to: #14445
Note that the class itself is transition in this PR. This PR is focused entirely on facilitating the transition to search-space immutability. Further work (starting in #14979 and #14987) will increase the abstraction and further alter the design into a new design pattern that will facilitate correction across word-boundary shifts, such as when fat-fingering a whitespace key.
Build-bot: skip build:web
Test-bot: skip