Skip to content

Commit

Permalink
Rollup merge of rust-lang#131462 - cuviper:open_buffered-error, r=Ral…
Browse files Browse the repository at this point in the history
…fJung

Mention allocation errors for `open_buffered`

This documents that `File::open_buffered` may return an error on allocation failure.
  • Loading branch information
matthiaskrgr authored Oct 9, 2024
2 parents 49220cd + db9377d commit 36a90d7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion std/src/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,8 @@ impl File {
///
/// # Errors
///
/// This function will return an error if `path` does not already exist.
/// This function will return an error if `path` does not already exist,
/// or if memory allocation fails for the new buffer.
/// Other errors may also be returned according to [`OpenOptions::open`].
///
/// # Examples
Expand Down

0 comments on commit 36a90d7

Please sign in to comment.