Branch: refs/heads/master Author: Colomban Wendling ban@herbesfolles.org Committer: Colomban Wendling ban@herbesfolles.org Date: Thu, 16 Nov 2023 09:47:12 UTC Commit: ffad343f21be323b55b3ca44c6f2d0d4d9a008fb https://github.com/geany/geany/commit/ffad343f21be323b55b3ca44c6f2d0d4d9a008...
Log Message: ----------- Fix harmless GCC warning
src/tagmanager/tm_ctags.c: In function 'rename_anon_tags': src/tagmanager/tm_ctags.c:323:68: warning: array subscript has type 'char' [-Wchar-subscripts] 323 | anon_counter = ++anon_counter_table[kind]; | ^
-Wchar-subscripts Warn if an array subscript has type "char". This is a common cause of error, as programmers often forget that this type is signed on some machines. This warning is enabled by -Wall.
Modified Paths: -------------- src/tagmanager/tm_ctags.c
Modified: src/tagmanager/tm_ctags.c 2 lines changed, 1 insertions(+), 1 deletions(-) =================================================================== @@ -320,7 +320,7 @@ static void rename_anon_tags(TMSourceFile *source_file) if (!anon_counter_table) anon_counter_table = g_new0(gint, 256);
- anon_counter = ++anon_counter_table[kind]; + anon_counter = ++anon_counter_table[(guchar) kind];
sprintf(buf, "anon_%s_%u", kind_name, anon_counter); tag->name = g_strdup(buf);
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).