Unified · Split
| @@ -1,6 +1,5 @@ | |||
| 1 | #![allow(missing_docs)] | 1 | #![allow(missing_docs)] |
| 2 | use git_hash::ObjectId; | 2 | use git_hash::ObjectId; |
| 3 | use git_object::CommitRefIter; | ||
| 4 | #[cfg(feature = "git-traverse")] | 3 | #[cfg(feature = "git-traverse")] |
| 5 | use git_traverse::commit::ancestors::{Ancestors, State}; | 4 | use git_traverse::commit::ancestors::{Ancestors, State}; |
| 6 | 5 | ||
| @@ -12,7 +11,7 @@ pub trait ObjectIdExt: Sealed { · 5 unmodified lines | |||
| 12 | #[cfg(feature = "git-traverse")] | 11 | #[cfg(feature = "git-traverse")] |
| 13 | fn ancestors_iter<Find>(self, find: Find) -> Ancestors<Find, fn(&git_hash::oid) -> bool, State> | 12 | fn ancestors_iter<Find>(self, find: Find) -> Ancestors<Find, fn(&git_hash::oid) -> bool, State> |
| 14 | where | 13 | where |
| 15 | Find: for<'a> FnMut(&git_hash::oid, &'a mut Vec<u8>) -> Option<CommitRefIter<'a>>; | 14 | Find: for<'a> FnMut(&git_hash::oid, &'a mut Vec<u8>) -> Option<git_object::CommitRefIter<'a>>; |
| 16 | 15 | ||
| 17 | fn attach<A: easy::Access + Sized>(self, access: &A) -> easy::Oid<'_, A>; | 16 | fn attach<A: easy::Access + Sized>(self, access: &A) -> easy::Oid<'_, A>; |
| 18 | } | 17 | } |
| @@ -23,7 +22,7 @@ impl ObjectIdExt for ObjectId { · 4 unmodified lines | |||
| 23 | #[cfg(feature = "git-traverse")] | 22 | #[cfg(feature = "git-traverse")] |
| 24 | fn ancestors_iter<Find>(self, find: Find) -> Ancestors<Find, fn(&git_hash::oid) -> bool, State> | 23 | fn ancestors_iter<Find>(self, find: Find) -> Ancestors<Find, fn(&git_hash::oid) -> bool, State> |
| 25 | where | 24 | where |
| 26 | Find: for<'a> FnMut(&git_hash::oid, &'a mut Vec<u8>) -> Option<CommitRefIter<'a>>, | 25 | Find: for<'a> FnMut(&git_hash::oid, &'a mut Vec<u8>) -> Option<git_object::CommitRefIter<'a>>, |
| 27 | { | 26 | { |
| 28 | Ancestors::new(Some(self), State::default(), find) | 27 | Ancestors::new(Some(self), State::default(), find) |
| 29 | } | 28 | } |