
AMDG Insert does not work correctly for maps that have had elements erased. typedef map2<pair<int, int>, pair<short, double> > my_map; typedef erase_key<my_map, int>::type map_with_int_erased; typedef insert<map_with_int_erased, pair<int, char> >::type final_map; final_map is m_item<*2*, int, char, m_mask<int, my_map> > This overwrites pair<short, double>. It ought to be m_item<*3*, int, char, m_mask<int, my_map> > Also, when insert is passed a key that is already present the old value is still present in addition to the new value. In Christ, Steven Watanabe

Steven Watanabe <steven@providere-consulting.com> writes:
AMDG
Insert does not work correctly for maps that have had elements erased.
typedef map2<pair<int, int>, pair<short, double> > my_map; typedef erase_key<my_map, int>::type map_with_int_erased; typedef insert<map_with_int_erased, pair<int, char> >::type final_map;
final_map is m_item<*2*, int, char, m_mask<int, my_map> > This overwrites pair<short, double>. It ought to be m_item<*3*, int, char, m_mask<int, my_map> >
Also, when insert is passed a key that is already present the old value is still present in addition to the new value.
Are you testing the Boost CVS, RC_1_34_0, or the 1.33.1 release? We have fixed lots of map bugs. -- Dave Abrahams Boost Consulting www.boost-consulting.com
participants (2)
-
David Abrahams
-
Steven Watanabe