File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -539,14 +539,11 @@ pub fn set_perm(p: &Path, perm: FilePermissions) -> io::Result<()> {
539
539
}
540
540
541
541
pub fn set_times ( _p : & Path , _times : FileTimes ) -> io:: Result < ( ) > {
542
- Err ( io :: const_error! ( io :: ErrorKind :: Unsupported , "setting file times not supported" , ) )
542
+ unsupported ( )
543
543
}
544
544
545
545
pub fn set_times_nofollow ( _p : & Path , _times : FileTimes ) -> io:: Result < ( ) > {
546
- Err ( io:: const_error!(
547
- io:: ErrorKind :: Unsupported ,
548
- "setting file times on symlinks not supported" ,
549
- ) )
546
+ unsupported ( )
550
547
}
551
548
552
549
pub fn rmdir ( p : & Path ) -> io:: Result < ( ) > {
Original file line number Diff line number Diff line change @@ -1201,6 +1201,7 @@ impl fmt::Debug for OpenOptions {
1201
1201
target_os = "horizon" ,
1202
1202
target_os = "nuttx" ,
1203
1203
) ) ) ]
1204
+ #[ inline( always) ]
1204
1205
fn to_timespec ( time : Option < SystemTime > ) -> io:: Result < libc:: timespec > {
1205
1206
match time {
1206
1207
Some ( time) if let Some ( ts) = time. t . to_timespec ( ) => Ok ( ts) ,
@@ -1217,6 +1218,7 @@ fn to_timespec(time: Option<SystemTime>) -> io::Result<libc::timespec> {
1217
1218
}
1218
1219
1219
1220
#[ cfg( target_vendor = "apple" ) ]
1221
+ #[ inline( always) ]
1220
1222
fn set_attrlist_with_times (
1221
1223
times : & FileTimes ,
1222
1224
) -> io:: Result < ( libc:: attrlist , [ mem:: MaybeUninit < libc:: timespec > ; 3 ] , usize ) > {
You can’t perform that action at this time.
0 commit comments