<p>In <a href="https://github.com/geany/geany/pull/957#discussion_r61960591">tagmanager/src/tm_parser.c</a>:</p>
<pre style='color:#555'>> +                            if (map->entries[i].kind == kinds[j])
> +                                  ctags_found = TRUE;
> +                          /* check that for every type in ctags there's a type in TM */
> +                          if (map->entries[j].kind == kinds[i])
> +                                  tm_found = TRUE;
> +                          if (ctags_found && tm_found)
> +                                  break;
> +                  }
> +                  if (!ctags_found)
> +                          g_warning("Tag type '%c' found in TM but not in ctags for %s",
> +                                  map->entries[i].kind, tm_ctags_get_lang_name(lang));
> +                  if (!tm_found)
> +                          g_warning("Tag type '%c' found in ctags but not in TM for %s",
> +                                  kinds[i], tm_ctags_get_lang_name(lang));
> +
> +                  presence_map[map->entries[i].kind]++;
</pre>
<pre lang="gcc"><code>../../../tagmanager/src/tm_parser.c: In function 'tm_parser_verify_type_mappings':
../../../tagmanager/src/tm_parser.c:637:16: warning: array subscript has type 'char' [-Wchar-subscripts]
    presence_map[map->entries[i].kind]++;
                ^
</code></pre>

<p>casting to <code>unsigned char</code> should be fine.</p>

<hr>

<p>BTW, <code>presence_map</code> could be 127 bytes only and indexed as <code>((unsigned char) map->entries[i].kind) & 0x0f</code>, kind names won't use non-ASCII letters.  But that's probably an over-optimization that might blow off on us someday.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly or <a href="https://github.com/geany/geany/pull/957/files/5d9376ea801a6e6c3ec22748741362a3a2eff7ac#r61960591">view it on GitHub</a><img alt="" height="1" src="https://github.com/notifications/beacon/ABDrJxUGDOKLnjqGehoH5emMWAxbHNbRks5p97_3gaJpZM4Ht-Ad.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/geany/geany/pull/957/files/5d9376ea801a6e6c3ec22748741362a3a2eff7ac#r61960591"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>