All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: git@vger.kernel.org
Subject: [PATCH 06/15] t/helper: mark more unused argv/argc arguments
Date: Sat, 17 Aug 2024 04:22:52 -0400	[thread overview]
Message-ID: <20240817082252.GF10287@coredump.intra.peff.net> (raw)
In-Reply-To: <20240817082101.GA6761@coredump.intra.peff.net>

This is a continuation of 126e3b3d2a (t/helper: mark unused argv/argc
arguments, 2023-03-28) to cover a few new cases:

 - test-example-tap was added since that commit

 - test-hashmap used to accept the "ignorecase" argument on the command
   line. But since most of its logic was moved to a unit-test in
   3469a23659 (t: port helper/test-hashmap.c to unit-tests/t-hashmap.c,
   2024-08-03), it now ignores its argv entirely.

Signed-off-by: Jeff King <peff@peff.net>
---
 t/helper/test-example-tap.c | 2 +-
 t/helper/test-hashmap.c     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/t/helper/test-example-tap.c b/t/helper/test-example-tap.c
index d072ad559f..f35667bd29 100644
--- a/t/helper/test-example-tap.c
+++ b/t/helper/test-example-tap.c
@@ -70,7 +70,7 @@ static void t_empty(void)
 	; /* empty */
 }
 
-int cmd__example_tap(int argc, const char **argv)
+int cmd__example_tap(int argc UNUSED, const char **argv UNUSED)
 {
 	test_res = TEST(check_res = check_int(1, ==, 1), "passing test");
 	TEST(t_res(1), "passing test and assertion return 1");
diff --git a/t/helper/test-hashmap.c b/t/helper/test-hashmap.c
index 195e6278be..7782ae585e 100644
--- a/t/helper/test-hashmap.c
+++ b/t/helper/test-hashmap.c
@@ -138,7 +138,7 @@ static void perf_hashmap(unsigned int method, unsigned int rounds)
  *
  * perfhashmap method rounds -> test hashmap.[ch] performance
  */
-int cmd__hashmap(int argc, const char **argv)
+int cmd__hashmap(int argc UNUSED, const char **argv UNUSED)
 {
 	struct string_list parts = STRING_LIST_INIT_NODUP;
 	struct strbuf line = STRBUF_INIT;
-- 
2.46.0.585.gd6679c16d8


  parent reply	other threads:[~2024-08-17  8:22 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-17  8:21 [PATCH 0/15] marking some more unused parameters Jeff King
2024-08-17  8:21 ` [PATCH 01/15] imap-send: mark unused parameter in ssl_socket_connect() fallback Jeff King
2024-08-17  8:21 ` [PATCH 02/15] update-ref: mark more unused parameters in parser callbacks Jeff King
2024-08-17  8:22 ` [PATCH 03/15] refs: mark unused parameters in ref_store fsck callbacks Jeff King
2024-08-17  8:22 ` [PATCH 04/15] refs: mark unused parameters in do_for_each_reflog_helper() Jeff King
2024-08-17  8:22 ` [PATCH 05/15] oss-fuzz: mark unused argv/argc argument Jeff King
2024-08-17  8:22 ` Jeff King [this message]
2024-08-17  8:23 ` [PATCH 07/15] unit-tests: ignore unused argc/argv Jeff King
2024-08-17  8:23 ` [PATCH 08/15] reftable: ignore unused argc/argv in test functions Jeff King
2024-08-17  8:24 ` [PATCH 09/15] reftable: drop obsolete test function declarations Jeff King
2024-08-17  8:24 ` [PATCH 10/15] reftable: mark unused parameters in virtual functions Jeff King
2024-08-17  8:24 ` [PATCH 11/15] t-hashmap: mark unused parameters in callback function Jeff King
2024-08-17 14:32   ` Ghanshyam Thakkar
2024-08-17 17:18     ` Jeff King
2024-08-17  8:25 ` [PATCH 12/15] test-mergesort: mark unused parameters in trivial callback Jeff King
2024-08-17  8:25 ` [PATCH 13/15] setup: mark unused parameter in config callback Jeff King
2024-08-17  8:25 ` [PATCH 14/15] daemon: mark unused parameters in non-posix fallbacks Jeff King
2024-08-17  8:25 ` [PATCH 15/15] scalar: mark unused parameters in dummy function Jeff King

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

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

  git send-email \
    --in-reply-to=20240817082252.GF10287@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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.