Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Add lifetime parameterization to async IPC reader #850

Closed
sydduckworth opened this issue Feb 17, 2022 · 0 comments · Fixed by #851
Closed

Add lifetime parameterization to async IPC reader #850

sydduckworth opened this issue Feb 17, 2022 · 0 comments · Fixed by #851
Labels
no-changelog Issues whose changes are covered by a PR and thus should not be shown in the changelog

Comments

@sydduckworth
Copy link
Contributor

Currently the async IPC reader (io::ipc::read::stream_async::AsyncStreamReader) has a 'static lifetime. It would be more ergonomic to parameterize its lifetime:

let mut buffer = futures::io::Cursor::new(Vec::new());
let reader = AsyncStreamReader::new(&mut buffer);
...
drop(reader);
let _out = reader.into_inner(); // This fails to compile because of the 'static mutable borrow
@jorgecarleitao jorgecarleitao added the no-changelog Issues whose changes are covered by a PR and thus should not be shown in the changelog label Mar 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
no-changelog Issues whose changes are covered by a PR and thus should not be shown in the changelog
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants