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

OpenOptions should implement std::os::unix::fs::OpenOptionsExt #2366

Closed
Sherlock-Holo opened this issue Apr 2, 2020 · 0 comments
Closed
Labels
A-tokio Area: The main tokio crate C-feature-request Category: A feature request. M-fs Module: tokio/fs

Comments

@Sherlock-Holo
Copy link

Version

0.2.15

Platform

linux

Description

I read docs.rs/tokio and find tokio::fs::OpenOptions doesn't implmenet trait std::os::unix::fs::OpenOptionsExt, I read the source codes, tokio::fs::OpenOptions juse a wrapper about std::fs::OpenOptions

pub struct OpenOptions(std::fs::OpenOptions);

If tokio::fs::OpenOptions could implement std::os::unix::fs::OpenOptionsExt, we could use it directly, instead of creating tokio::fs::OpenOptions from std::fs::OpenOptions

@Darksonn Darksonn added A-tokio Area: The main tokio crate C-feature-request Category: A feature request. E-easy Call for participation: Experience needed to fix: Easy / not much E-help-wanted Call for participation: Help is requested to fix this issue. M-fs Module: tokio/fs labels Apr 29, 2020
chovine pushed a commit to chovine/tokio that referenced this issue May 11, 2020
Trait std::os::unix::fs::OpenOptionsExt is now implemented for
fs::OpenOption.

In order to access the underlying std::fs::OpenOptions wrapped in
tokio's OpenOption, an `as_inner_mut` method was added to OpenOption,
only visible to the parent module.

Fixes: tokio-rs#2366
jensim pushed a commit to jensim/tokio that referenced this issue Jun 7, 2020
Trait OpenOptionsExt is now implemented for fs::OpenOption.

In order to access the underlying std::fs::OpenOptions wrapped in
tokio's OpenOption, an as_inner_mut method was added to OpenOption,
only visible to the parent module.

Fixes: tokio-rs#2366
@Darksonn Darksonn removed E-easy Call for participation: Experience needed to fix: Easy / not much E-help-wanted Call for participation: Help is requested to fix this issue. labels Jul 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-tokio Area: The main tokio crate C-feature-request Category: A feature request. M-fs Module: tokio/fs
Projects
None yet
Development

No branches or pull requests

2 participants