pedantic compiler warnings: double semicolons, function to data pointers

Eric van Gyzen eric at vangyzen.net
Tue May 19 19:12:45 UTC 2015


On 05/19/2015 14:42, Luigi Rizzo wrote:
> While trying to compile some of my (kernel) code in different environments,
> i noticed a couple of errors that perhaps might be worth fixing
>
> - extra semicolons. These come either from explicit repetitions in the code
>   (see the output of a grep at the end of this message),
>   or sometimes from the epansion of macros such as BITSET_DEFINE()
>
>
> - conversion between function and data pointers. One is in mbuf.h
>
>   m->m_ext.ext_free = m->m_ext.ext_arg1 = m->m_ext.ext_arg2 = NULL;
>
>
> Shuold we care/bother to fix these as we step through them ?

I would say yes, since that would reduce the noise in the compiler warning output.  I realize the warning could be disabled, but cleaning up the ~50 occurrences [of ;;] seems like the better way.

Eric


More information about the freebsd-current mailing list