public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/51142] New: [C++0x] map::erase(key) doesn't compile with -D_GLIBCXX_DEBUG.
@ 2011-11-15 16:33 pluto at agmk dot net
  2011-11-15 16:38 ` [Bug libstdc++/51142] " redi at gcc dot gnu.org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: pluto at agmk dot net @ 2011-11-15 16:33 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51142

             Bug #: 51142
           Summary: [C++0x] map::erase(key) doesn't compile with
                    -D_GLIBCXX_DEBUG.
    Classification: Unclassified
           Product: gcc
           Version: 4.6.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: pluto@agmk.net


Created attachment 25828
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25828
testcase

$ LANG=C make
g++ -Wall -std=c++0x t.cpp -c --save-temps -D_GLIBCXX_DEBUG
In file included from /usr/include/c++/4.6.2/debug/map:34:0,
                 from /usr/include/c++/4.6.2/map:66,
                 from t.cpp:2:
/usr/include/c++/4.6.2/debug/map.h: In member function 'std::__debug::map<_Key,
_Tp, _Compare, _Allocator>::size_type std::__debug::map<_Key, _Tp, _Compare,
_Allocator>::erase(const key_type&) [with _Key = boost::variant<bool>, _Tp =
unsigned int, _Compare = std::less<boost::variant<bool> >, _Allocator =
std::allocator<std::pair<const boost::variant<bool>, unsigned int> >,
std::__debug::map<_Key, _Tp, _Compare, _Allocator>::size_type = long unsigned
int, std::__debug::map<_Key, _Tp, _Compare, _Allocator>::key_type =
boost::variant<bool>]':
t.cpp:10:15:   instantiated from here
/usr/include/c++/4.6.2/debug/map.h:295:6: error: call of overloaded
'erase(std::__debug::map<boost::variant<bool>, unsigned int>::_Base_iterator&)'
is ambiguous
/usr/include/c++/4.6.2/debug/map.h:295:6: note: candidates are:
/usr/include/c++/4.6.2/bits/stl_map.h:613:7: note: std::__cxx1998::map<_Key,
_Tp, _Compare, _Alloc>::iterator std::__cxx1998::map<_Key, _Tp, _Compare,
_Alloc>::erase(std::__cxx1998::map<_Key, _Tp, _Compare,
_Alloc>::const_iterator) [with _Key = boost::variant<bool>, _Tp = unsigned int,
_Compare = std::less<boost::variant<bool> >, _Alloc =
std::allocator<std::pair<const boost::variant<bool>, unsigned int> >,
std::__cxx1998::map<_Key, _Tp, _Compare, _Alloc>::iterator =
std::_Rb_tree_iterator<std::pair<const boost::variant<bool>, unsigned int> >,
std::__cxx1998::map<_Key, _Tp, _Compare, _Alloc>::const_iterator =
std::_Rb_tree_const_iterator<std::pair<const boost::variant<bool>, unsigned
int> >]
/usr/include/c++/4.6.2/bits/stl_map.h:643:7: note: std::__cxx1998::map<_Key,
_Tp, _Compare, _Alloc>::size_type std::__cxx1998::map<_Key, _Tp, _Compare,
_Alloc>::erase(const key_type&) [with _Key = boost::variant<bool>, _Tp =
unsigned int, _Compare = std::less<boost::variant<bool> >, _Alloc =
std::allocator<std::pair<const boost::variant<bool>, unsigned int> >,
std::__cxx1998::map<_Key, _Tp, _Compare, _Alloc>::size_type = long unsigned
int, std::__cxx1998::map<_Key, _Tp, _Compare, _Alloc>::key_type =
boost::variant<bool>]
make: *** [all] Error 1


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2011-11-16 23:13 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-15 16:33 [Bug libstdc++/51142] New: [C++0x] map::erase(key) doesn't compile with -D_GLIBCXX_DEBUG pluto at agmk dot net
2011-11-15 16:38 ` [Bug libstdc++/51142] " redi at gcc dot gnu.org
2011-11-15 17:02 ` redi at gcc dot gnu.org
2011-11-15 17:05 ` paolo.carlini at oracle dot com
2011-11-15 17:35 ` redi at gcc dot gnu.org
2011-11-15 17:40 ` paolo.carlini at oracle dot com
2011-11-16  0:37 ` paolo at gcc dot gnu.org
2011-11-16 17:30 ` pluto at agmk dot net
2011-11-16 17:55 ` paolo.carlini at oracle dot com
2011-11-16 23:36 ` paolo at gcc dot gnu.org
2011-11-17  0:50 ` paolo.carlini at oracle dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).