Re: [PATCH 1/3] t9350: point out that refs are not updated correctly
- From
Sverre Rabbelier <srabbelier@gmail.com>
- Date
- Oct 25, 2012, 07:43 UTC
- Message-ID
- <CAGdFq_j5sWsHwJY-rWP-XJ6cMF6uwSq=9beFe9ZuZyixBa1fVA@mail.gmail.com>
- In-Reply-To
- <20121025073454.GB15790@elie.Belkin>
On Thu, Oct 25, 2012 at 12:34 AM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 19 quoted lines
> If I remember right, '^foo1' is (whence == REV_CMD_REV) with (flags ==
> UNINTERESTING). That's why sequencer.c checks for unadorned revs like
> this:
>
> if (opts->revs->cmdline.nr == 1 &&
> opts->revs->cmdline.rev->whence == REV_CMD_REV &&
> opts->revs->no_walk &&
> !opts->revs->cmdline.rev->flags) {
>
> Maybe
>
> if (elem->flags & UNINTERESTING)
> continue;
> if (elem->whence == REV_CMD_PARENTS_ONLY) /* foo^@ */
> continue;
>
> would work well here? That would handle bizarre cases like "--not
> next..master" (and ordinary cases like "master...next") better, by
> focusing on the semantics instead of syntax.I know there was a reason why using UNINTERESTING didn't work (otherwise we could've used that to start with, instead of needing Junio's whence solution). I think all refs ended up being marked as UNINTERESTING or somesuch.
-- Cheers, Sverre Rabbelier