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

No documentation of dropping behaviour for std::fs::File #52685

Closed
alercah opened this issue Jul 25, 2018 · 1 comment
Closed

No documentation of dropping behaviour for std::fs::File #52685

alercah opened this issue Jul 25, 2018 · 1 comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools P-medium Medium priority

Comments

@alercah
Copy link
Contributor

alercah commented Jul 25, 2018

The dropping behaviour for std::fs::File is inherited through the sys::fs::File object, meaning that its documentation does not come through to the File type. As a result, there is no documentation of the behaviour of File and, in particular, the decision to swallow errors (likely the correct one, but it should nonetheless be documented).

@alercah
Copy link
Contributor Author

alercah commented Jul 25, 2018

(there is a sentence "Files are automatically closed when they go out of scope.", but this doesn't discuss error handling, and it does not accurately reflect the fact that a drop and going out of scope are not the same thing.)

@retep998 retep998 added the A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools label Jul 26, 2018
@steveklabnik steveklabnik added the P-medium Medium priority label Dec 27, 2018
Centril added a commit to Centril/rust that referenced this issue Apr 4, 2019
…dtolnay

Document std::fs::File close behavior ignoring errors

Resolves rust-lang#52685
Centril added a commit to Centril/rust that referenced this issue Apr 4, 2019
…dtolnay

Document std::fs::File close behavior ignoring errors

Resolves rust-lang#52685
Centril added a commit to Centril/rust that referenced this issue Apr 4, 2019
…dtolnay

Document std::fs::File close behavior ignoring errors

Resolves rust-lang#52685
Centril added a commit to Centril/rust that referenced this issue Apr 4, 2019
…dtolnay

Document std::fs::File close behavior ignoring errors

Resolves rust-lang#52685
Centril added a commit to Centril/rust that referenced this issue Apr 4, 2019
…dtolnay

Document std::fs::File close behavior ignoring errors

Resolves rust-lang#52685
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools P-medium Medium priority
Projects
None yet
Development

No branches or pull requests

3 participants