On 12 Nov 2013 at 18:03, Tom Browder wrote:
Ref the -Wshadow warning in particular: IMHO, the obstinate and continued use of a shadowed name (just because one thinks one can get away with it) in a well-respected library like Boost is not good for business nor the author's reputation.
I personally deliberately and intentionally shadow both variable and type names in non-public namespaces where doing so significantly eases my maintenance costs. One particular area where this can be needed is getting some code to compile across differing levels of native STL C++ 11 compliance where you want either Boost's or the STL's implementation to get selected. None of this pollutes any public namespace - I therefore see no reason why I should be stopped from making my life easier. Bugs in my use of shadowing are entirely my problem, not someone else's. Niall -- Currently unemployed and looking for work. Work Portfolio: http://careers.stackoverflow.com/nialldouglas/