Skip to content

Commit

Permalink
doc: Update "cmp" links in tree::function::diff
Browse files Browse the repository at this point in the history
This updates the "git_cmp_c" and "git_cmp_rs" links in the
`gix_diff::tree::function::diff` documentation comment.

- The significant change is to the "git_cmp_rs" link (the second
  link), which accounts for how files have renamed and how code has
  been moved, and also changed in GitoxideLabs#849 to fix issue GitoxideLabs#848.

  This hyperlink change completes the third task listed in GitoxideLabs#1627.

- The other change is to update the "git_cmp_c" link at the same
  time. That code has not changed, and this is just referring to a
  later commit (the current tip of the master branch in git/git).

  The reason to also do this change is to make it easier to verify,
  both now and for anyone reading the documentation, that that link
  remains current.
  • Loading branch information
EliahKagan committed Oct 14, 2024
1 parent 795962b commit 991c939
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gix-diff/src/tree/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ use crate::tree::{visit::Change, Error, State, TreeInfoTuple, Visit};
/// * cycle checking is not performed, but can be performed in the delegate which can return
/// [`tree::visit::Action::Cancel`](crate::tree::visit::Action::Cancel) to stop the traversal.
///
/// [git_cmp_c]: https://github.com/git/git/blob/311531c9de557d25ac087c1637818bd2aad6eb3a/tree-diff.c#L49:L65
/// [git_cmp_rs]: https://github.com/GitoxideLabs/gitoxide/blob/a4d5f99c8dc99bf814790928a3bf9649cd99486b/gix-object/src/mutable/tree.rs#L52-L55
/// [git_cmp_c]: https://github.com/git/git/blob/ef8ce8f3d4344fd3af049c17eeba5cd20d98b69f/tree-diff.c#L72-L88
/// [git_cmp_rs]: https://github.com/GitoxideLabs/gitoxide/blob/795962b107d86f58b1f7c75006da256d19cc80ad/gix-object/src/tree/mod.rs#L263-L273
#[doc(alias = "diff_tree_to_tree", alias = "git2")]
pub fn diff<StateMut>(
lhs: TreeRefIter<'_>,
Expand Down

0 comments on commit 991c939

Please sign in to comment.