Skip to content

Commit

Permalink
Warn that platform-specific behavior may change
Browse files Browse the repository at this point in the history
  • Loading branch information
sourcefrog committed Mar 30, 2022
1 parent 93e9f5e commit cfee2ed
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion library/std/src/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1739,7 +1739,7 @@ pub fn rename<P: AsRef<Path>, Q: AsRef<Path>>(from: P, to: Q) -> io::Result<()>
///
/// On MacOS, this function corresponds to `fclonefileat` and `fcopyfile`.
///
/// Note that, this [may change in the future][changes].
/// Note that platform-specific behavior [may change in the future][changes].
///
/// [changes]: io#platform-specific-behavior
///
Expand Down
4 changes: 4 additions & 0 deletions library/std/src/io/copy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ use crate::mem::MaybeUninit;
/// On Linux (including Android), this function uses `copy_file_range(2)`,
/// `sendfile(2)` or `splice(2)` syscalls to move data directly between file
/// descriptors if possible.
///
/// Note that platform-specific behavior [may change in the future][changes].
///
/// [changes]: crate::io#platform-specific-behavior
#[stable(feature = "rust1", since = "1.0.0")]
pub fn copy<R: ?Sized, W: ?Sized>(reader: &mut R, writer: &mut W) -> Result<u64>
where
Expand Down

0 comments on commit cfee2ed

Please sign in to comment.