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

Add method drain for Vec, like std::vec::Vec? #334

Closed
remme123 opened this issue Jan 7, 2023 · 1 comment · Fixed by #444 · May be fixed by #365
Closed

Add method drain for Vec, like std::vec::Vec? #334

remme123 opened this issue Jan 7, 2023 · 1 comment · Fixed by #444 · May be fixed by #365

Comments

@remme123
Copy link

remme123 commented Jan 7, 2023

std drain retures a new struct Drain, but heapless can drop the drained data by using method copy_within & truncate.

@korken89
Copy link
Contributor

Sounds useful, could you make a PR for the feature?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants