@@ -7,9 +7,7 @@ use crate::sys;
7
7
use crate :: sys:: platform:: fs:: MetadataExt as UnixMetadataExt ;
8
8
use crate :: sys_common:: { AsInner , AsInnerMut , FromInner } ;
9
9
10
- /// Unix-specific extensions to [`File`].
11
- ///
12
- /// [`File`]: ../../../../std/fs/struct.File.html
10
+ /// Unix-specific extensions to [`fs::File`].
13
11
#[ stable( feature = "file_offset" , since = "1.15.0" ) ]
14
12
pub trait FileExt {
15
13
/// Reads a number of bytes starting from a given offset.
@@ -24,7 +22,7 @@ pub trait FileExt {
24
22
/// Note that similar to [`File::read`], it is not an error to return with a
25
23
/// short read.
26
24
///
27
- /// [`File::read`]: ../../../../std/fs/struct. File.html#method. read
25
+ /// [`File::read`]: fs:: File:: read
28
26
///
29
27
/// # Examples
30
28
///
@@ -55,8 +53,8 @@ pub trait FileExt {
55
53
///
56
54
/// Similar to [`Read::read_exact`] but uses [`read_at`] instead of `read`.
57
55
///
58
- /// [`Read::read_exact`]: ../../../../std/io/trait. Read.html#method. read_exact
59
- /// [`read_at`]: #tymethod. read_at
56
+ /// [`Read::read_exact`]: io:: Read:: read_exact
57
+ /// [`read_at`]: FileExt:: read_at
60
58
///
61
59
/// # Errors
62
60
///
@@ -75,8 +73,8 @@ pub trait FileExt {
75
73
/// has read, but it will never read more than would be necessary to
76
74
/// completely fill the buffer.
77
75
///
78
- /// [`ErrorKind::Interrupted`]: ../../../../std/io/enum. ErrorKind.html#variant. Interrupted
79
- /// [`ErrorKind::UnexpectedEof`]: ../../../../std/io/enum. ErrorKind.html#variant. UnexpectedEof
76
+ /// [`ErrorKind::Interrupted`]: io:: ErrorKind:: Interrupted
77
+ /// [`ErrorKind::UnexpectedEof`]: io:: ErrorKind:: UnexpectedEof
80
78
///
81
79
/// # Examples
82
80
///
@@ -132,7 +130,7 @@ pub trait FileExt {
132
130
/// Note that similar to [`File::write`], it is not an error to return a
133
131
/// short write.
134
132
///
135
- /// [`File::write`]: ../../../../std/fs/struct. File.html#method. write
133
+ /// [`File::write`]: fs:: File:: write
136
134
///
137
135
/// # Examples
138
136
///
@@ -171,8 +169,8 @@ pub trait FileExt {
171
169
/// This function will return the first error of
172
170
/// non-[`ErrorKind::Interrupted`] kind that [`write_at`] returns.
173
171
///
174
- /// [`ErrorKind::Interrupted`]: ../../../../std/io/enum. ErrorKind.html#variant. Interrupted
175
- /// [`write_at`]: #tymethod. write_at
172
+ /// [`ErrorKind::Interrupted`]: io:: ErrorKind:: Interrupted
173
+ /// [`write_at`]: FileExt:: write_at
176
174
///
177
175
/// # Examples
178
176
///
@@ -223,8 +221,6 @@ impl FileExt for fs::File {
223
221
}
224
222
225
223
/// Unix-specific extensions to [`fs::Permissions`].
226
- ///
227
- /// [`fs::Permissions`]: ../../../../std/fs/struct.Permissions.html
228
224
#[ stable( feature = "fs_ext" , since = "1.1.0" ) ]
229
225
pub trait PermissionsExt {
230
226
/// Returns the underlying raw `st_mode` bits that contain the standard
@@ -300,8 +296,6 @@ impl PermissionsExt for Permissions {
300
296
}
301
297
302
298
/// Unix-specific extensions to [`fs::OpenOptions`].
303
- ///
304
- /// [`fs::OpenOptions`]: ../../../../std/fs/struct.OpenOptions.html
305
299
#[ stable( feature = "fs_ext" , since = "1.1.0" ) ]
306
300
pub trait OpenOptionsExt {
307
301
/// Sets the mode bits that a new file will be created with.
@@ -369,8 +363,6 @@ impl OpenOptionsExt for OpenOptions {
369
363
*/
370
364
371
365
/// Unix-specific extensions to [`fs::Metadata`].
372
- ///
373
- /// [`fs::Metadata`]: ../../../../std/fs/struct.Metadata.html
374
366
#[ stable( feature = "metadata_ext" , since = "1.1.0" ) ]
375
367
pub trait MetadataExt {
376
368
/// Returns the ID of the device containing the file.
@@ -650,12 +642,10 @@ impl MetadataExt for fs::Metadata {
650
642
}
651
643
}
652
644
653
- /// Unix-specific extensions for [`FileType`].
645
+ /// Unix-specific extensions for [`fs:: FileType`].
654
646
///
655
647
/// Adds support for special Unix file types such as block/character devices,
656
648
/// pipes, and sockets.
657
- ///
658
- /// [`FileType`]: ../../../../std/fs/struct.FileType.html
659
649
#[ stable( feature = "file_type_ext" , since = "1.5.0" ) ]
660
650
pub trait FileTypeExt {
661
651
/// Returns whether this file type is a block device.
@@ -749,8 +739,6 @@ impl FileTypeExt for fs::FileType {
749
739
}
750
740
751
741
/// Unix-specific extension methods for [`fs::DirEntry`].
752
- ///
753
- /// [`fs::DirEntry`]: ../../../../std/fs/struct.DirEntry.html
754
742
#[ stable( feature = "dir_entry_ext" , since = "1.1.0" ) ]
755
743
pub trait DirEntryExt {
756
744
/// Returns the underlying `d_ino` field in the contained `dirent`
@@ -811,8 +799,6 @@ pub fn symlink<P: AsRef<Path>, Q: AsRef<Path>>(src: P, dst: Q) -> io::Result<()>
811
799
}
812
800
813
801
/// Unix-specific extensions to [`fs::DirBuilder`].
814
- ///
815
- /// [`fs::DirBuilder`]: ../../../../std/fs/struct.DirBuilder.html
816
802
#[ stable( feature = "dir_builder" , since = "1.6.0" ) ]
817
803
pub trait DirBuilderExt {
818
804
/// Sets the mode to create new directories with. This option defaults to
0 commit comments