new warnings from basic_string
Lars Gullik Bjønnes
larsbj@gullik.net
Fri Jan 28 01:04:00 GMT 2005
larsbj@gullik.net (Lars Gullik Bjønnes) writes:
| I will try to find a small example that shows this.
Seems that _GLIBCXX_DEBUG is now required to trigger it.
#define _GLIBCXX_DEBUG 1
#include <map>
void foo()
{
typedef std::map<int, int> MangledMap;
MangledMap mangledNames;
MangledMap::const_iterator it = mangledNames.find(0);
}
Gives me stuff like:
/opt/gcc-head/lib/gcc/i686-pc-linux-gnu/4.0.0/../../../../include/c++/4.0.0/debug/formatter.h:
In function #bool __gnu_debug::operator==(const
__gnu_debug::_Safe_iterator<_Iterator, _Sequence>&, const
__gnu_debug::_Safe_iterator<_Iterator, _Sequence>&) [with _Iterator =
std::_Rb_tree_iterator<std::pair<const int, int> >, _Sequence =
__gnu_debug_def::map<int, int, std::less<int>,
std::allocator<std::pair<const int, int> > >]#:
/opt/gcc-head/lib/gcc/i686-pc-linux-gnu/4.0.0/../../../../include/c++/4.0.0/debug/formatter.h:227:
warning: control may reach end of non-void function #bool
__gnu_debug::_Safe_iterator<_Iterator, _Sequence>::_M_is_begin() const
[with _Iterator = std::_Rb_tree_iterator<std::pair<const int, int> >,
_Sequence = __gnu_debug_def::map<int, int, std::less<int>,
std::allocator<std::pair<const int, int> > >]# being inlined
--
Lgb
More information about the Libstdc++
mailing list