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

Feat/typing history #96

Merged
merged 5 commits into from
Jul 4, 2023
Merged

Feat/typing history #96

merged 5 commits into from
Jul 4, 2023

Conversation

tarkah
Copy link
Member

@tarkah tarkah commented Jul 4, 2023

Resolves #85

// Clear message, we parsed it succesfully
state.input = String::new();
// Clear message and add it to history
state.history.push_front(std::mem::take(&mut state.input));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this grow unbounded?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point, we should probably have some limit

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

64905a2

I've truncated to 100 here. Shouldn't have much memory footprint and is more than enough.

Copy link
Member

@casperstorm casperstorm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, great feature.

@tarkah tarkah merged commit dacb740 into main Jul 4, 2023
1 check passed
@tarkah tarkah deleted the feat/typing-history branch July 4, 2023 20:54
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.

Typing history
3 participants