Hi,
As I said on IRC I have hit a bug while working on a VMOD and then on
Varnish itself. I thought I had seen other false-positives but that's
the only one, in several places.
Basically it complains when you use it in an if or while statement or
I suppose anything that expects a condition, because it interprets the
outer set of parentheses as a hint not to warn about assignment. So
we've gone full circle on this one!
Do we use this kind of condition in Varnish?
if ((var = expr))
If not I suggest we disable it in autogen.des, my workaround is to use gcc.
I haven't tried clang above 3.7.0, but basically it is _not_ looking
at preprocessed code, in which we obviously don't have the outer
parentheses:
if (VTAILQ_EMPTY(...))
make -k log attached.
Current Travis CI continuous integration uses clang 3.4 FYI.
Best Regards,
Dridi
As I said on IRC I have hit a bug while working on a VMOD and then on
Varnish itself. I thought I had seen other false-positives but that's
the only one, in several places.
Basically it complains when you use it in an if or while statement or
I suppose anything that expects a condition, because it interprets the
outer set of parentheses as a hint not to warn about assignment. So
we've gone full circle on this one!
Do we use this kind of condition in Varnish?
if ((var = expr))
If not I suggest we disable it in autogen.des, my workaround is to use gcc.
I haven't tried clang above 3.7.0, but basically it is _not_ looking
at preprocessed code, in which we obviously don't have the outer
parentheses:
if (VTAILQ_EMPTY(...))
make -k log attached.
Current Travis CI continuous integration uses clang 3.4 FYI.
Best Regards,
Dridi