16813 – compiler error in DEBUG version of range insertion std::map::insert (original) (raw)

| Description Matt Austern 2004-07-29 00:02:51 UTC Compiling the following test case #define _GLIBCXX_DEBUG #include int main( int argc, char * argv[ ] ) { std::map< int, float > m1, m2; m1[ 3 ] = 3.0f; m1[ 11 ] = -67.0f; m2.insert( m1.begin( ), m1.end( ) ); return 0; } Gives this error: [tmp]$ /work/root.fsf/bin/g++ -c foo.cc /Volumes/Data/work/root.fsf/bin/../lib/gcc/powerpc-apple-darwin7.4.0/3.5.0/../../../../include/ c++/3.5.0/debug/map.h: In member function `void __gnu_debug_def::map<_Key, _Tp, _Compare, _Allocator>::insert(_InputIterator, _InputIterator) [with _InputIterator = __gnu_debug:: _Safe_iterator<std::_Rb_tree_iterator<std::pair<const int, float> >, __gnu_debug_def::map<int, float, std::less, std::allocator<std::pair<const int, float> > > >, _Key = int, _Tp = float, _Compare = std::less, _Allocator = std::allocator<std::pair<const int, float> >]': foo.cc:12: instantiated from here /Volumes/Data/work/root.fsf/bin/../lib/gcc/powerpc-apple-darwin7.4.0/3.5.0/../../../../include/ c++/3.5.0/debug/map.h:166: error: `__glibcxx_valid_range' was not declared in this scope Comment 1 Drea Pinski 2004-07-29 00:06:59 UTC Confirmed. Comment 2 Paolo Carlini 2004-07-29 09:51:46 UTC Just a trivial typo: __glibcxx_valid_range for __glibcxx_check_valid_range. I'm fixing it everywhere. Comment 5 Paolo Carlini 2004-07-29 12:10:05 UTC Fixed for mainline and 3.4.2. | | | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | |