diff --git a/include/boost/multi_index/composite_key.hpp b/include/boost/multi_index/composite_key.hpp index 2ea6c87..66042d6 100644 --- a/include/boost/multi_index/composite_key.hpp +++ b/include/boost/multi_index/composite_key.hpp @@ -531,6 +531,16 @@ struct composite_key_result /* composite_key */ +/* NB. Some overloads of operator() have an extra dummy parameter int=0. + * This disambiguator serves several purposes: + * - Without it, MSVC++ 6.0 incorrectly regards some overloads as + * specializations of a previous member function template. + * - MSVC++ 6.0/7.0 seem to incorrectly treat some different memfuns + * as if they have the same signature. + * - If remove_const is broken due to lack of PTS, int=0 avoids the + * declaration of memfuns with identical signature. + */ + template< typename Value, BOOST_MULTI_INDEX_CK_ENUM(BOOST_MULTI_INDEX_CK_TEMPLATE_PARM,KeyFromValue) diff --git a/include/boost/multi_index/identity.hpp b/include/boost/multi_index/identity.hpp index 6a375b8..509ac68 100644 --- a/include/boost/multi_index/identity.hpp +++ b/include/boost/multi_index/identity.hpp @@ -34,9 +34,13 @@ namespace detail{ */ /* NB. Some overloads of operator() have an extra dummy parameter int=0. - * This is so because MSVC++ 6.0 otherwise *incorrectly* regards these - * overloads as specializations of a previous member function template. - * Left for all compilers as it does no harm. + * This disambiguator serves several purposes: + * - Without it, MSVC++ 6.0 incorrectly regards some overloads as + * specializations of a previous member function template. + * - MSVC++ 6.0/7.0 seem to incorrectly treat some different memfuns + * as if they have the same signature. + * - If remove_const is broken due to lack of PTS, int=0 avoids the + * declaration of memfuns with identical signature. */ template diff --git a/include/boost/multi_index/mem_fun.hpp b/include/boost/multi_index/mem_fun.hpp index d083bd6..9ea90cc 100644 --- a/include/boost/multi_index/mem_fun.hpp +++ b/include/boost/multi_index/mem_fun.hpp @@ -30,6 +30,16 @@ namespace multi_index{ * arbitrary combinations of these (vg. T** or auto_ptr.) */ +/* NB. Some overloads of operator() have an extra dummy parameter int=0. + * This disambiguator serves several purposes: + * - Without it, MSVC++ 6.0 incorrectly regards some overloads as + * specializations of a previous member function template. + * - MSVC++ 6.0/7.0 seem to incorrectly treat some different memfuns + * as if they have the same signature. + * - If remove_const is broken due to lack of PTS, int=0 avoids the + * declaration of memfuns with identical signature. + */ + template struct const_mem_fun { diff --git a/include/boost/multi_index/member.hpp b/include/boost/multi_index/member.hpp index e30df53..52b274f 100644 --- a/include/boost/multi_index/member.hpp +++ b/include/boost/multi_index/member.hpp @@ -33,9 +33,13 @@ namespace detail{ */ /* NB. Some overloads of operator() have an extra dummy parameter int=0. - * This is so because MSVC++ 6.0 otherwise *incorrectly* regards these - * overloads as specializations of a previous member function template. - * Left for all compilers as it does no harm. + * This disambiguator serves several purposes: + * - Without it, MSVC++ 6.0 incorrectly regards some overloads as + * specializations of a previous member function template. + * - MSVC++ 6.0/7.0 seem to incorrectly treat some different memfuns + * as if they have the same signature. + * - If remove_const is broken due to lack of PTS, int=0 avoids the + * declaration of memfuns with identical signature. */ template