Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] compdescribe fix for unsorted groups (workers/34814) (was: Re: completion: git: --fixup: problem with _describe -2V and duplicate commit subjects)
- X-seq: zsh-workers 35162
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: "Zsh Hackers' List" <zsh-workers@xxxxxxx>
- Subject: Re: [PATCH] compdescribe fix for unsorted groups (workers/34814) (was: Re: completion: git: --fixup: problem with _describe -2V and duplicate commit subjects)
- Date: Sat, 16 May 2015 21:07:35 -0700
- In-reply-to: <20150516225422.GH1976@tarsus.local2>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <5510AAD4.8040807@thequod.de> <20150329054753.GA2766@tarsus.local2> <20150514143627.GE1932@tarsus.local2> <20150516225422.GH1976@tarsus.local2>
On May 16, 10:54pm, Daniel Shahaf wrote:
} Subject: Re: [PATCH] compdescribe fix for unsorted groups (workers/34814)
}
} Daniel Shahaf wrote on Thu, May 14, 2015 at 14:36:27 +0000:
} > The first attached patch seems to address this. However, I encountered
} > an odd problem with it, which I have not been able to narrow down. When
} > I apply the first patch, Daniel Hahler's recent series, and the second
} > attached patch, and then try to complete 'git checkout 1<TAB>',¹ I get
} > first a screenful of hashes, and then a screenful of descriptions, and
} > so on alternating. I'm not sure whether this indicates a bug in the
} > first patch or an independent problem.
}
} To be explicit: the problem goes away if I revert the first patch, but
} keep the others applied.
You mean revert *all* of "PATCH 1/3", that is, both the compcore.c hunk
(which seems to be a functional no-op) and all the hunks of computil.c?
The only difference I see from eyballing the patch in 35127 is in the
computil.c cd_get() hunk where before -2V would be set only on an
existing -J group, but post-patch might be set on an existing -V group.
I don't know why that would matter unless there is both a -J and a -V
group in the same set of opts, in which case -2V is going to be set for
whichever group is encountered first? Am I understanding the intent of
this code correctly?
In any case I can't reproduce your reported problem, at least not quite
as you explain it above.
Starting from commit d52bf91659522435d68f719389095001f050b6c5, I applied
DH's seven patches and then your 35127, and:
torch% git checkout 1<TAB>
torch% git checkout 15
153a99d -- 35154: NEWS on arithmetic evaluation changes (2 days ago)
15aa99b -- 35139: complete the new (b) parameter flag (2 days ago)
153a99d -- 35154: NEWS on arithmetic evaluation changes (2 days ago)
15aa99b -- 35139: complete the new (b) parameter flag (2 days ago)
That doesn't really look correct because it lists everything twice, but
I get exactly the same thing with computil.c backed out. If I back out
the rest of 35127, I get:
torch% git checkout 1<TAB>
torch% git checkout 15
153a99d -- [HEAD^^] 35154: NEWS on arithmetic evaluation changes (2 days a
15aa99b -- [HEAD~6] 35139: complete the new (b) parameter flag (2 days ago
153a99d -- [HEAD^^] 35154: NEWS on arithmetic evaluation changes (2 days a
15aa99b -- [HEAD~6] 35139: complete the new (b) parameter flag (2 days ago
Which I guess are not strictly duplicates because the descriptions differ.
If I then revert all of DH's patches (back to an empty 'git diff'):
torch% git checkout 1<TAB>
torch% git checkout 15
153a99d -- [153a99d] 35154: NEWS on arithmetic evaluation changes
15aa99b -- [15aa99b] 35139: complete the new (b) parameter flag
The extra line for each of these is a side-effect from DH's patch 3/7 in
workers/35101.
Incidentally _git_recent_objects is missing a "return ret" at the end (but
repairing that doesn't change the duplication).
Messages sorted by:
Reverse Date,
Date,
Thread,
Author