On Sat, Nov 9, 2013 at 4:32 AM, Eric Prud'hommeaux
On Fri, Nov 08, 2013 at 06:31:25PM -0600, Tom Browder wrote:
I am trying to use Boost 1.54.0 to replace a previous version (1.47) and am using g++ 4.7 with most warnings turned on. I am getting many -Wshadow errors and wonder why they exist. Surely the developers test for such. ... Or they may, and any convention for managing shadowing applied to
* Lars Viklund
[2013-11-09 10:23+0100] headers would trivially enable a coder to enable shadowing warnings on their own code. This potentially saves them mysterious bugs and sniffing around in a debugger before finding that it was something the compiler could have told them about if it weren't lost in the noise. I agree with not being religious about it, but -Wshadow is a pretty achievable goal.
And it would certainly "boost" Boost's already wide-spread reputation of excellence.
Warnings are not errors for a reason, they exist as advice that may or may not apply.
And that's why it's important to release warning-free code to outsiders who can't always easily determine the true intent of the original author. I am using Boost to help support the well-respected BRL-CAD package (http://brlcad.org) whose policy is to release warning-free code, so Boost releases being warning-free would be a very good thing. Thanks for the insightful comments. Best regards, -Tom