From: "SZEDER Gábor" <szeder.dev@gmail.com>
To: "Carlo Marcelo Arenas Belón" <carenas@gmail.com>
Cc: git@vger.kernel.org, pclouds@gmail.com, peff@peff.net,
chriscool@tuxfamily.org, l.s.r@web.de,
ramsay@ramsayjones.plus.com, Junio C Hamano <gitster@pobox.com>
Subject: Re: [PATCH v3 2/3] khash: silence -Wunused-function in delta-islands from khash
Date: Thu, 25 Oct 2018 13:30:45 +0200 [thread overview]
Message-ID: <20181025113045.GM30222@szeder.dev> (raw)
In-Reply-To: <20181025110427.13655-3-carenas@gmail.com>
On Thu, Oct 25, 2018 at 04:04:26AM -0700, Carlo Marcelo Arenas Belón wrote:
> showing the following when compiled with latest clang (OpenBSD, Fedora
> and macOS):
s/^s/S/
This applies to your other commit messages as well.
But more importantly, please be explicit about the compiler version
that emits the warning, so others won't have to guess when stumbling
upon this commit in a few months or years time.
> delta-islands.c:23:1: warning: unused function 'kh_destroy_str'
> [-Wunused-function]
> delta-islands.c:23:1: warning: unused function 'kh_clear_str'
> [-Wunused-function]
> delta-islands.c:23:1: warning: unused function 'kh_del_str' [-Wunused-function]
>
> Reported-by: René Scharfe <l.s.r@web.de>
> Suggested-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
> Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
> khash.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/khash.h b/khash.h
> index d10caa0c35..532109c87f 100644
> --- a/khash.h
> +++ b/khash.h
> @@ -234,7 +234,7 @@ static const double __ac_HASH_UPPER = 0.77;
> __KHASH_IMPL(name, SCOPE, khkey_t, khval_t, kh_is_map, __hash_func, __hash_equal)
>
> #define KHASH_INIT(name, khkey_t, khval_t, kh_is_map, __hash_func, __hash_equal) \
> - KHASH_INIT2(name, static inline, khkey_t, khval_t, kh_is_map, __hash_func, __hash_equal)
> + KHASH_INIT2(name, MAYBE_UNUSED static inline, khkey_t, khval_t, kh_is_map, __hash_func, __hash_equal)
>
> /* Other convenient macros... */
>
> --
> 2.19.1
>
next prev parent reply other threads:[~2018-10-25 11:30 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-25 11:04 [PATCH v3 0/3] delta-islands: avoid unused function messages Carlo Marcelo Arenas Belón
2018-10-25 11:04 ` [PATCH v3 1/3] commit-slab: move MAYBE_UNUSED into git-compat-util Carlo Marcelo Arenas Belón
2018-10-25 11:04 ` [PATCH v3 2/3] khash: silence -Wunused-function in delta-islands from khash Carlo Marcelo Arenas Belón
2018-10-25 11:30 ` SZEDER Gábor [this message]
2018-10-25 11:04 ` [PATCH v3 3/3] commit-slab: missing definitions and forward declarations (hdr-check) Carlo Marcelo Arenas Belón
2018-10-25 18:54 ` Ramsay Jones
2018-10-25 21:08 ` Ramsay Jones
2018-10-26 3:15 ` Carlo Arenas
2018-10-27 1:45 ` Ramsay Jones
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=20181025113045.GM30222@szeder.dev \
--to=szeder.dev@gmail.com \
--cc=carenas@gmail.com \
--cc=chriscool@tuxfamily.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=l.s.r@web.de \
--cc=pclouds@gmail.com \
--cc=peff@peff.net \
--cc=ramsay@ramsayjones.plus.com \
/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 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 NNTP newsgroup(s).