From d41851602e0be989ada14ebe6b5ecffcb2e89d86 Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Mon, 19 Feb 2024 10:48:39 -0800 Subject: [PATCH] Remove redundant imports. --- src/call.rs | 3 --- src/commit.rs | 1 - src/config.rs | 1 - src/cred.rs | 1 - src/oid.rs | 1 - src/pathspec.rs | 2 +- src/remote.rs | 1 - src/repo.rs | 1 - src/signature.rs | 1 - src/tree.rs | 2 +- src/util.rs | 1 - 11 files changed, 2 insertions(+), 13 deletions(-) diff --git a/src/call.rs b/src/call.rs index d9fd234681..95350d2690 100644 --- a/src/call.rs +++ b/src/call.rs @@ -1,5 +1,4 @@ #![macro_use] -use libc; use crate::Error; @@ -54,8 +53,6 @@ mod impls { use std::ffi::CString; use std::ptr; - use libc; - use crate::call::Convert; use crate::{raw, BranchType, ConfigLevel, Direction, ObjectType, ResetType}; use crate::{ diff --git a/src/commit.rs b/src/commit.rs index 4887e927e6..7fef508096 100644 --- a/src/commit.rs +++ b/src/commit.rs @@ -1,4 +1,3 @@ -use libc; use std::iter::FusedIterator; use std::marker; use std::mem; diff --git a/src/config.rs b/src/config.rs index ae5c4ff63a..6f12efc322 100644 --- a/src/config.rs +++ b/src/config.rs @@ -1,4 +1,3 @@ -use libc; use std::ffi::CString; use std::marker; use std::path::{Path, PathBuf}; diff --git a/src/cred.rs b/src/cred.rs index 72d9485e82..fc4af1e4eb 100644 --- a/src/cred.rs +++ b/src/cred.rs @@ -5,7 +5,6 @@ use std::mem; use std::path::Path; use std::process::{Command, Stdio}; use std::ptr; -use url; use crate::util::Binding; use crate::{raw, Config, Error, IntoCString}; diff --git a/src/oid.rs b/src/oid.rs index 145458aec0..35516cb181 100644 --- a/src/oid.rs +++ b/src/oid.rs @@ -1,4 +1,3 @@ -use libc; use std::cmp::Ordering; use std::fmt; use std::hash::{Hash, Hasher}; diff --git a/src/pathspec.rs b/src/pathspec.rs index 48174fcc19..16850dc210 100644 --- a/src/pathspec.rs +++ b/src/pathspec.rs @@ -1,5 +1,5 @@ use libc::size_t; -use std::iter::{FusedIterator, IntoIterator}; +use std::iter::FusedIterator; use std::marker; use std::ops::Range; use std::path::Path; diff --git a/src/remote.rs b/src/remote.rs index 807c108e1d..a15a095010 100644 --- a/src/remote.rs +++ b/src/remote.rs @@ -1,4 +1,3 @@ -use libc; use raw::git_strarray; use std::iter::FusedIterator; use std::marker; diff --git a/src/repo.rs b/src/repo.rs index 93176183fb..b41b42480c 100644 --- a/src/repo.rs +++ b/src/repo.rs @@ -1,7 +1,6 @@ use libc::{c_char, c_int, c_uint, c_void, size_t}; use std::env; use std::ffi::{CStr, CString, OsStr}; -use std::iter::IntoIterator; use std::mem; use std::path::{Path, PathBuf}; use std::ptr; diff --git a/src/signature.rs b/src/signature.rs index 83fbbf5935..7c9ffb3933 100644 --- a/src/signature.rs +++ b/src/signature.rs @@ -1,4 +1,3 @@ -use libc; use std::ffi::CString; use std::fmt; use std::marker; diff --git a/src/tree.rs b/src/tree.rs index 31170ab5e1..ae8fe3b4c5 100644 --- a/src/tree.rs +++ b/src/tree.rs @@ -1,4 +1,4 @@ -use libc::{self, c_char, c_int, c_void}; +use libc::{c_char, c_int, c_void}; use std::cmp::Ordering; use std::ffi::{CStr, CString}; use std::iter::FusedIterator; diff --git a/src/util.rs b/src/util.rs index 5f735bc004..4065492f76 100644 --- a/src/util.rs +++ b/src/util.rs @@ -1,7 +1,6 @@ use libc::{c_char, c_int, size_t}; use std::cmp::Ordering; use std::ffi::{CString, OsStr, OsString}; -use std::iter::IntoIterator; use std::path::{Component, Path, PathBuf}; use crate::{raw, Error};