[Xcb] Remove declaration-after-statement C warning (was: Patch for compiler warnings in util-image)

Bart Massey bart at cs.pdx.edu
Thu Aug 29 13:37:18 PDT 2013


Thank you!

Reviewed-By: Bart Massey <bart at cs.pdx.edu>

On Wed, Aug 28, 2013 at 7:21 PM, Arnaud Fontaine <arnaud at andesi.org> wrote:
> Hello,
>
> Cc'ing xorg-devel as -Wdeclaration-after-statement is actually defined
> in xorg/util/macros.
>
> Alan Coopersmith <alan.coopersmith at oracle.com> writes:
>
>> On 08/23/13 01:04 AM, Arnaud Fontaine wrote:
>>> Good to know, thanks! Does this mean -Wdeclaration-after-statement can
>>> be removed from util/macros/xorg-macros.m4.in then? From my
>>> understanding, AC_PROG_CC_C99 is already the default, so this should not
>>> be an issue to remove this flag, right?
>>
>> If Xorg decides to update the common coding style to allow these, then
>> yes - it's just a style guideline now, no longer a portability issue.
>
> At least X server specifies some mandatory C extensions[0] (from [1]),
> including interleaved code and declarations.
>
> I guess this warning can be removed (feel free to correct me if I'm
> wrong), so I have attached a patch for util/macros.
>
> Cheers,
> --
> Arnaud Fontaine
>
> [0] http://cgit.freedesktop.org/xorg/xserver/tree/doc/c-extensions
> [1] http://www.x.org/wiki/CodingStyle/
>
>
> _______________________________________________
> Xcb mailing list
> Xcb at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/xcb


More information about the xorg-devel mailing list