Skip to content

Commit 2544945

Browse files
peffgitster
authored andcommitted
xdiff: drop xpparam_t parameter from histogram cmp_recs()
Since 663c5ad (diff histogram: intern strings, 2021-11-17), our cmp_recs() does not call xdl_recmatch(), and thus no longer needs an xpparam_t struct from which to get the flags. We can drop the unused parameter from the function, as well as the macro which wraps it. There's no functional change here; it's just simplifying things (and making -Wunused-parameter happier). Signed-off-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent cf0b26d commit 2544945

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

xdiff/xhistogram.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,15 +88,14 @@ struct region {
8888
#define REC(env, s, l) \
8989
(env->xdf##s.recs[l - 1])
9090

91-
static int cmp_recs(xpparam_t const *xpp,
92-
xrecord_t *r1, xrecord_t *r2)
91+
static int cmp_recs(xrecord_t *r1, xrecord_t *r2)
9392
{
9493
return r1->ha == r2->ha;
9594

9695
}
9796

9897
#define CMP(i, s1, l1, s2, l2) \
99-
(cmp_recs(i->xpp, REC(i->env, s1, l1), REC(i->env, s2, l2)))
98+
(cmp_recs(REC(i->env, s1, l1), REC(i->env, s2, l2)))
10099

101100
#define TABLE_HASH(index, side, line) \
102101
XDL_HASHLONG((REC(index->env, side, line))->ha, index->table_bits)

0 commit comments

Comments
 (0)