Skip to content

Commit 0ada4b9

Browse files
peffgitster
authored andcommitted
diffcore-pickaxe: mark unused parameters in pickaxe functions
We have a virtual pickaxe_fn for handling -G versus -S pickaxe options. They need to take the same set of parameters, but of course they care about different ones (e.g., a regex -G will never use a kwset). Mark the unused ones to appease -Wunused-parameter. Signed-off-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent dfd2a23 commit 0ada4b9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

diffcore-pickaxe.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ static int diffgrep_consume(void *priv, char *line, unsigned long len)
3838

3939
static int diff_grep(mmfile_t *one, mmfile_t *two,
4040
struct diff_options *o,
41-
regex_t *regexp, kwset_t kws)
41+
regex_t *regexp, kwset_t kws UNUSED)
4242
{
4343
struct diffgrep_cb ecbdata;
4444
xpparam_t xpp;
@@ -114,7 +114,7 @@ static unsigned int contains(mmfile_t *mf, regex_t *regexp, kwset_t kws,
114114
}
115115

116116
static int has_changes(mmfile_t *one, mmfile_t *two,
117-
struct diff_options *o,
117+
struct diff_options *o UNUSED,
118118
regex_t *regexp, kwset_t kws)
119119
{
120120
unsigned int c1 = one ? contains(one, regexp, kws, 0) : 0;

0 commit comments

Comments
 (0)