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

Use our own io::Cursor #1943

Merged
merged 1 commit into from
Nov 4, 2019
Merged

Use our own io::Cursor #1943

merged 1 commit into from
Nov 4, 2019

Conversation

taiki-e
Copy link
Member

@taiki-e taiki-e commented Nov 4, 2019

Based on #1936

Context: #1829

If both futures::io ext traits and std::io traits are imported, method names may conflict, so use our own.

cc @Nemo157

/// [bytes]: https://doc.rust-lang.org/std/primitive.slice.html
#[derive(Clone, Debug, Default)]
pub struct Cursor<T> {
inner: io::Cursor<T>,
Copy link
Member Author

@taiki-e taiki-e Nov 4, 2019

Choose a reason for hiding this comment

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

As there is not enough time, it is implemented as a newtype, but it can be optimized later.

@cramertj cramertj marked this pull request as ready for review November 4, 2019 23:02
@cramertj
Copy link
Member

cramertj commented Nov 4, 2019

Works for me, thanks!

@cramertj cramertj merged commit 38b908f into rust-lang:master Nov 4, 2019
@taiki-e taiki-e deleted the io-cursor branch November 5, 2019 05:28
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.

2 participants