2 2

Enabling -Wshadow

Cristian Ontivero
Details
Message ID
<CALvFPys=SsjLpQc7HG-J_ZCU6VKUhT63tzk4U_Si=YC-SpJM8Q@mail.gmail.com>
Sender timestamp
1548859669
DKIM signature
pass
Download raw message
Both GCC and Clang support the `-Wshadow` flag to warn about cases
where a variable shadows another, which potentially signifies a bug.

Would you consider enabling it? If you think it's a good idea, I can
submit a patch fixing the different occurrences so that mrsh compiles
with `-Wshadow`.
Details
Message ID
<20190130145144.GA27624@homura.localdomain>
In-Reply-To
<CALvFPys=SsjLpQc7HG-J_ZCU6VKUhT63tzk4U_Si=YC-SpJM8Q@mail.gmail.com> (view parent)
Sender timestamp
1548859905
DKIM signature
pass
Download raw message
Personally I often find shadowing useful.
Details
Message ID
<90zo1wdYGeBXPgJQNiB9tacRFbyFEsWi1pwxGrqWimwMxEQ-6Unp_vCa7PC80FWQ8TP6b2I0UD3l6QqQvnbEbxJJDC5nV1gjheec7iquLN8=@emersion.fr>
In-Reply-To
<20190130145144.GA27624@homura.localdomain> (view parent)
Sender timestamp
1548871813
DKIM signature
pass
Download raw message
On Wednesday, January 30, 2019 3:51 PM, Drew DeVault <sir@cmpwn.com> wrote:
> Personally I often find shadowing useful.

Yeah, me too. I'd prefer not to do this for now.