
17 Aug
2005
17 Aug
'05
10:58 a.m.
Vadim Zeitlin wrote:
Hello,
when compiling <boost/algorithm/string/trim.hpp> with MSVC 7.1 at maximal warning level you get a warning 4512 ("assignment operator could not be generated") because of the const members in struct is_classifiedF from boost/algorithm/string/detail/classification.hpp.
The trivial patch below fixes it. Notice that I didn't take the assignment operator in "#ifdef _MSC_VER" because I see no harm in doing this for all compilers but then no other compiler I know about gives such warning so it should be also safe to add the #ifdef if this is preferred.
Wouldn't it be even better to provide a new baseclass boost::nonassignable that is similar to boost::noncopyable ? That makes things even more explicit. Regards, Stefan