Thanks for checking this so quickly!
Charles Diza wrote:
error.c:386:12: warning: data argument not used by format string
That one is a false alarm. The format string might contain fewer formats than
there are arguments, and C allows this so the behavior is well-defined. Writing
it differently would hurt performance slightly.
CC strstr.o
In file included from regex.c:70:
./regex_internal.c:1392:11: warning: comparison of unsigned expression < 0
is
always false [-Wtautological-compare]
if (idx < 0 || idx >= set->nelem)
~~~ ^ ~
Another false alarm. On some configurations idx is signed and so the test is
needed there. It's harmless (no code generated) on your platform, where idx is
unsigned.
I assume these are Clang warnings.
Does the second warning go away if the code looks like this?
if (((Idx) -1 < 0 && idx < 0) || idx >= set->nelem)
Dunno if it's worth this sort of obfuscation just to pacify Clang, tho....