Boost logo

Boost :

Subject: Re: [boost] nested BOOST_FOREACH and -Wshadow
From: Richard Webb (richard.webb_at_[hidden])
Date: 2009-02-07 10:27:13


Dustin Spicuzza wrote:
>
>
> shadowtest.cpp:13: warning: declaration of ‘_foreach_col’ shadows a
> previous local
> shadowtest.cpp:12: warning: shadowed declaration is here
> shadowtest.cpp:13: warning: declaration of ‘_foreach_cur’ shadows a
> previous local
> shadowtest.cpp:12: warning: shadowed declaration is here
> shadowtest.cpp:13: warning: declaration of ‘_foreach_end’ shadows a
> previous local
> shadowtest.cpp:12: warning: shadowed declaration is here
> shadowtest.cpp:13: warning: declaration of ‘_foreach_continue’ shadows a
> previous local
> shadowtest.cpp:12: warning: shadowed declaration is here
>
>

You get similar warnings to this with VC9 if you build with code analysis
enabled.
I've silenced this in my local copy by extending the existing
BOOST_FOREACH_SUPPRESS_WARNINGS macro to suppress warning C6246 as well as
the existing C6001.

-- 
View this message in context: http://www.nabble.com/nested-BOOST_FOREACH-and--Wshadow-tp21886255p21889459.html
Sent from the Boost - Dev mailing list archive at Nabble.com.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk