
From: "Stephan T. Lavavej" <stl@nuwen.net>
I have noted the following about Boost 1.32.0.
2. boost/format/format_implementation.hpp contains shadowing on line 28. The constructor takes 'str', which is named identically to a member function.
3. boost/date_time/time_duration.hpp contains shadowing on line 53. The constructor takes 'hours', 'minutes', and 'seconds', which are named identically to member functions.
4. boost/date_time/time_system_counted.hpp contains shadowing on line 34. The constructor takes 'tod', which is named identically to a member function.
Shadowing makes using Boost with GCC -Wshadow difficult, and these cases are very easy to fix.
I find that partitioning names is helpful. I use suffixes to separate the names of formal parameters and data members from other names. I don't distinguish between automatic variables and member functions, however. - data members use a trailing underscore - formal parameters use a directional suffix: "_i," "_o," or "_io" Some scheme like that could help the above libraries. -- Rob Stewart stewart@sig.com Software Engineer http://www.sig.com Susquehanna International Group, LLP using std::disclaimer;