Skip to content
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

refactor: reduce clone usage #48

Merged

Conversation

StoneDot
Copy link
Contributor

@StoneDot StoneDot commented Nov 29, 2021

Issue #, if available:
This PR is related to #6.

Description of changes:
This PR reduces the use of clone.
There are primary and accompanying goals such as:

  • Reduce clone to improve performance.
  • Currently, there is no good way to update the context cache without quitting the program. It causes an incoherent cache on shell mode. Mutable reference is a way to solve this problem. As of this pull request, we have not introduced a cache update.
  • Give future ability into context to hold another cache like "item cache," which is required to implement completions.

I welcome the discussion to achieve the above goals.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@StoneDot StoneDot requested a review from kzym-w November 29, 2021 10:40
@StoneDot StoneDot self-assigned this Dec 5, 2021
@StoneDot StoneDot force-pushed the change-context-to-mutable-borrow branch 3 times, most recently from b6d3b9d to b5493c9 Compare May 24, 2024 17:08
@StoneDot StoneDot changed the title Refactor: Reduce clone of context object refactor: reduce clone of context object May 24, 2024
@StoneDot StoneDot force-pushed the change-context-to-mutable-borrow branch from b5493c9 to 2299ba5 Compare May 24, 2024 17:17
@StoneDot StoneDot marked this pull request as ready for review May 24, 2024 17:18
@StoneDot StoneDot requested a review from a team as a code owner May 24, 2024 17:18
@StoneDot StoneDot marked this pull request as draft May 24, 2024 17:39
@StoneDot StoneDot force-pushed the change-context-to-mutable-borrow branch from 2299ba5 to f5189ab Compare May 24, 2024 19:08
@StoneDot StoneDot changed the title refactor: reduce clone of context object refactor: reduce clone usage May 24, 2024
@StoneDot StoneDot force-pushed the change-context-to-mutable-borrow branch from f5189ab to 1ff3edc Compare May 24, 2024 19:09
@StoneDot StoneDot marked this pull request as ready for review May 24, 2024 19:11
@StoneDot StoneDot force-pushed the change-context-to-mutable-borrow branch from 1ff3edc to 4861258 Compare May 25, 2024 07:30
Signed-off-by: Hiroaki Goto <hiroag@amazon.com>
@ryota-sakamoto ryota-sakamoto force-pushed the change-context-to-mutable-borrow branch from 4861258 to 0b1de00 Compare May 27, 2024 05:17
@ryota-sakamoto ryota-sakamoto merged commit 30c11d2 into awslabs:main May 27, 2024
5 checks passed
@StoneDot StoneDot deleted the change-context-to-mutable-borrow branch May 27, 2024 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants