git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: git@vger.kernel.org
Subject: [PATCH 6/9] xdiff: mark unused parameter in xdl_call_hunk_func()
Date: Tue, 13 Dec 2022 06:13:24 -0500	[thread overview]
Message-ID: <Y5heVMGLAQpWq39E@coredump.intra.peff.net> (raw)
In-Reply-To: <Y5hdvpbLpXySHFRz@coredump.intra.peff.net>

This function is used interchangeably with xdl_emit via a function
pointer, so we can't just drop the unused parameter. Mark it to silence
-Wunused-parameter.

Signed-off-by: Jeff King <peff@peff.net>
---
 xdiff/xdiffi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xdiff/xdiffi.c b/xdiff/xdiffi.c
index 32652ded2d..344c2dfc3e 100644
--- a/xdiff/xdiffi.c
+++ b/xdiff/xdiffi.c
@@ -973,7 +973,7 @@ void xdl_free_script(xdchange_t *xscr) {
 	}
 }
 
-static int xdl_call_hunk_func(xdfenv_t *xe, xdchange_t *xscr, xdemitcb_t *ecb,
+static int xdl_call_hunk_func(xdfenv_t *xe UNUSED, xdchange_t *xscr, xdemitcb_t *ecb,
 			      xdemitconf_t const *xecfg)
 {
 	xdchange_t *xch, *xche;
-- 
2.39.0.546.g5ea984bc66


  parent reply	other threads:[~2022-12-13 11:15 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-13 11:10 [PATCH 0/9] more -Wunused-parameter fixes/annotations Jeff King
2022-12-13 11:11 ` [PATCH 1/9] ls-refs: use repository parameter to iterate refs Jeff King
2022-12-13 11:11 ` [PATCH 2/9] blob: drop unused parts of parse_blob_buffer() Jeff King
2022-12-13 11:12 ` [PATCH 3/9] list-objects: drop process_gitlink() function Jeff King
2022-12-13 11:12 ` [PATCH 4/9] ws: drop unused parameter from ws_blank_line() Jeff King
2022-12-13 11:13 ` [PATCH 5/9] xdiff: drop unused parameter in def_ff() Jeff King
2022-12-13 11:13 ` Jeff King [this message]
2022-12-13 11:13 ` [PATCH 7/9] diff: mark unused parameters in callbacks Jeff King
2022-12-13 11:14 ` [PATCH 8/9] list-objects-filter: mark unused parameters in virtual functions Jeff King
2022-12-13 11:16 ` [PATCH 9/9] userdiff: mark unused parameter in internal callback Jeff King
2022-12-14  1:38 ` [PATCH 0/9] more -Wunused-parameter fixes/annotations 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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=Y5heVMGLAQpWq39E@coredump.intra.peff.net \
    --to=peff@peff.net \
    --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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).