summaryrefslogtreecommitdiff
path: root/commit.h
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2023-08-31 17:21:28 -0400
committerJunio C Hamano <gitster@pobox.com>2023-09-05 14:48:17 -0700
commit34bf44f2d50e835a4824a07c139bdececccf4da1 (patch)
treeda25bba200bcb5a9ba3918713ac1d7b80b9bbd78 /commit.h
parent66e3309294571ada0e45ea78a2cfb649f08b9dd4 (diff)
parse-options: mark unused "opt" parameter in callbacks
The previous commit argued that parse-options callbacks should try to use opt->value rather than touching globals directly. In some cases, however, that's awkward to do. Some callbacks touch multiple variables, or may even just call into an abstracted function that does so. In some of these cases we _could_ convert them by stuffing the multiple variables into a single struct and passing the struct pointer through opt->value. But that may make other parts of the code less readable, as the struct relationship has to be mentioned everywhere. Let's just accept that these cases are special and leave them as-is. But we do need to mark their "opt" parameters to satisfy -Wunused-parameter. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit.h')
0 files changed, 0 insertions, 0 deletions