Skip to content

Add BytesMut::try_reserve()#521

Closed
Guiguiprim wants to merge 1 commit into
tokio-rs:masterfrom
Guiguiprim:add-try-reserve
Closed

Add BytesMut::try_reserve()#521
Guiguiprim wants to merge 1 commit into
tokio-rs:masterfrom
Guiguiprim:add-try-reserve

Conversation

@Guiguiprim
Copy link
Copy Markdown

@Guiguiprim Guiguiprim commented Dec 13, 2021

Add support for fallible allocation by adding BytesMut::try_reserve().

This does change the MSRV to 1.57, so I don't know how we should handle it.
Adding it under a feature flag, so that people can choose not to use it ?

Fixes #484

@Guiguiprim Guiguiprim changed the title Add BytesMut::try_reserve() #484 Add BytesMut::try_reserve() Dec 13, 2021
@paolobarbolini
Copy link
Copy Markdown
Contributor

paolobarbolini commented Dec 20, 2021

@Guiguiprim I wouldn't say this fixes #484, as it would be nice to also get fallible allocations on the rest of the APIs

@Guiguiprim
Copy link
Copy Markdown
Author

Closing as @poliorcetics refreshed this in a new PR.

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.

Fallible allocations?

2 participants