Skip to content

Commit 08e05a5

Browse files
authored
refactor: remove redundant imports to fix CI (#2320)
* refactor: remove redundant imports to fix CI * refactor: remove redundant imports to fix CI
1 parent 197f55b commit 08e05a5

File tree

7 files changed

+2
-8
lines changed

7 files changed

+2
-8
lines changed

src/errno.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use crate::Result;
1515
use cfg_if::cfg_if;
1616
use libc::{c_int, c_void};
17-
use std::convert::TryFrom;
1817
use std::{error, fmt, io};
1918

2019
pub use self::consts::*;

src/fcntl.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
use crate::errno::Errno;
33
#[cfg(all(target_os = "freebsd", target_arch = "x86_64"))]
44
use core::slice;
5-
use libc::{self, c_int, c_uint, size_t, ssize_t};
5+
use libc::{c_int, c_uint, size_t, ssize_t};
66
#[cfg(any(
77
target_os = "netbsd",
88
apple_targets,

src/sys/time.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
// https://github.com/rust-lang/libc/issues/1848
33
pub use libc::{suseconds_t, time_t};
44
use libc::{timespec, timeval};
5-
use std::convert::From;
65
use std::time::Duration;
76
use std::{cmp, fmt, ops};
87

src/unistd.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,7 @@ use crate::{Error, NixPath, Result};
3131
#[cfg(not(target_os = "redox"))]
3232
use cfg_if::cfg_if;
3333
use libc::{
34-
self, c_char, c_int, c_long, c_uint, gid_t, mode_t, off_t, pid_t, size_t,
35-
uid_t,
34+
c_char, c_int, c_long, c_uint, gid_t, mode_t, off_t, pid_t, size_t, uid_t,
3635
};
3736
use std::convert::Infallible;
3837
#[cfg(not(target_os = "redox"))]

test/sys/test_select.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ macro_rules! generate_fdset_bad_fd_tests {
6868

6969
mod test_fdset_too_large_fd {
7070
use super::*;
71-
use std::convert::TryInto;
7271
generate_fdset_bad_fd_tests!(
7372
FD_SETSIZE.try_into().unwrap(),
7473
insert,

test/sys/test_signal.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
use nix::errno::Errno;
22
use nix::sys::signal::*;
33
use nix::unistd::*;
4-
use std::convert::TryFrom;
54
use std::hash::{Hash, Hasher};
65
use std::sync::atomic::{AtomicBool, Ordering};
76
#[cfg(not(target_os = "redox"))]

test/sys/test_termios.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
use std::convert::TryFrom;
21
use std::os::unix::io::{AsFd, AsRawFd};
32
use tempfile::tempfile;
43

0 commit comments

Comments
 (0)