[Mesa-dev] building with -Wshadow
Emil Velikov
emil.l.velikov at gmail.com
Wed Feb 10 15:34:19 UTC 2016
Hi Dave,
On 10 February 2016 at 04:43, Dave Airlie <airlied at gmail.com> wrote:
> I was just messing with warning flags on virglrenderer and noticed
> -Wshadow generated a fair few warnings with gallium, so I did a mesa
> build with -Wshadow enabled and it was fairly messy,
>
> do we care? there could be bugs hiding in -Wshadow land.
>
Huge thanks for bringing this up.
TL;DR; Yes please :-)
Longer version: Ideally we'll be using (almost) the same flags as
libdrm and xserver at some point. Note that older versions of GCC are
likely to cause a few annoying warnings [1] here and there. Worst case
scenario, we can toggle it off inline in the places where people feel
unhappy with the fix.
-Emil
[1] http://stackoverflow.com/questions/2958457/gcc-wshadow-is-too-strict
More information about the mesa-dev
mailing list