git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Subject: [WIP PATCH 1/6] diff-lib.c: fix misleading comments on oneway_diff()
Date: Sat, 19 Sep 2009 22:06:10 -0700	[thread overview]
Message-ID: <1253423175-6339-2-git-send-email-gitster@pobox.com> (raw)
In-Reply-To: <1253423175-6339-1-git-send-email-gitster@pobox.com>

20a16eb (unpack_trees(): fix diff-index regression., 2008-03-10) adjusted
diff-index to the new world order since 34110cd (Make 'unpack_trees()'
have a separate source and destination index, 2008-03-06).  Callbacks are
expected to return anything non-negative as "success", and instead of
reporting how many index entries they have processed, they are expected to
advance o->pos themselves.  The code did so, but a stale comment was left
behind.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 diff-lib.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/diff-lib.c b/diff-lib.c
index 0c74ef5..adf1c5f 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -383,7 +383,7 @@ static inline void skip_same_name(struct cache_entry *ce, struct unpack_trees_op
  * For diffing, the index is more important, and we only have a
  * single tree.
  *
- * We're supposed to return how many index entries we want to skip.
+ * We're supposed to advance o->pos to skip what we have already processed.
  *
  * This wrapper makes it all more readable, and takes care of all
  * the fairly complex unpack_trees() semantic requirements, including
-- 
1.6.5.rc1.90.ga3b1b

  reply	other threads:[~2009-09-20  5:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-20  5:06 [WIP PATCH 0/6] Merging with D/F conflicts Junio C Hamano
2009-09-20  5:06 ` Junio C Hamano [this message]
2009-09-20  5:06 ` [WIP PATCH 2/6] unpack-trees: typofix Junio C Hamano
2009-09-20  5:06 ` [WIP PATCH 3/6] unpack_callback(): use unpack_failed() consistently Junio C Hamano
2009-09-20  5:06 ` [WIP PATCH 4/6] traverse_trees(): handle D/F conflict case sanely Junio C Hamano
2009-09-20  5:06 ` [WIP PATCH 5/6] unpack-trees.c: prepare for looking ahead in the index Junio C Hamano
2009-09-20  5:06 ` [WIP PATCH 6/6] read-tree --debug-unpack Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1253423175-6339-2-git-send-email-gitster@pobox.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).