diff options
| author | Tobias Bucher <tobiasbucher5991@gmail.com> | 2016-10-14 23:02:47 +0200 |
|---|---|---|
| committer | Tobias Bucher <tobiasbucher5991@gmail.com> | 2016-10-14 23:02:47 +0200 |
| commit | 15549935f8dd110a67229531d02018279cbbe34b (patch) | |
| tree | 38cda8c564467a7eb580f35f1e242568066e048c | |
| parent | 94aa08b66cb624155f2fb84f01fd5d9eab3c0c7a (diff) | |
| download | rust-15549935f8dd110a67229531d02018279cbbe34b.tar.gz rust-15549935f8dd110a67229531d02018279cbbe34b.zip | |
Android: Fix unused-imports warning
| -rw-r--r-- | src/libstd/sys/unix/android.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libstd/sys/unix/android.rs b/src/libstd/sys/unix/android.rs index 8b11d077daf..10436723a81 100644 --- a/src/libstd/sys/unix/android.rs +++ b/src/libstd/sys/unix/android.rs @@ -31,7 +31,6 @@ use libc::{c_int, c_void, sighandler_t, size_t, ssize_t}; use libc::{ftruncate, pread, pwrite}; -use convert::TryInto; use io; use super::{cvt, cvt_r}; @@ -128,6 +127,7 @@ pub fn ftruncate64(fd: c_int, size: u64) -> io::Result<()> { pub unsafe fn cvt_pread64(fd: c_int, buf: *mut c_void, count: size_t, offset: i64) -> io::Result<ssize_t> { + use convert::TryInto; weak!(fn pread64(c_int, *mut c_void, size_t, i64) -> ssize_t); pread64.get().map(|f| cvt(f(fd, buf, count, offset))).unwrap_or_else(|| { if let Ok(o) = offset.try_into() { @@ -143,6 +143,7 @@ pub unsafe fn cvt_pread64(fd: c_int, buf: *mut c_void, count: size_t, offset: i6 pub unsafe fn cvt_pwrite64(fd: c_int, buf: *const c_void, count: size_t, offset: i64) -> io::Result<ssize_t> { + use convert::TryInto; weak!(fn pwrite64(c_int, *const c_void, size_t, i64) -> ssize_t); pwrite64.get().map(|f| cvt(f(fd, buf, count, offset))).unwrap_or_else(|| { if let Ok(o) = offset.try_into() { |
