Commit 919e5c5e by Paolo Carlini Committed by Paolo Carlini

forward_list.tcc (operator==): Use auto.

2008-10-16  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/forward_list.tcc (operator==): Use auto.

From-SVN: r141173
parent a39562d9
2008-10-16 Paolo Carlini <paolo.carlini@oracle.com> 2008-10-16 Paolo Carlini <paolo.carlini@oracle.com>
* include/bits/forward_list.tcc (operator==): Use auto.
2008-10-16 Paolo Carlini <paolo.carlini@oracle.com>
* include/bits/forward_list.h (_Fwd_list_base<>::_M_insert_after): * include/bits/forward_list.h (_Fwd_list_base<>::_M_insert_after):
Move out of line, tweak to return _Fwd_list_node_base*. Move out of line, tweak to return _Fwd_list_node_base*.
(forward_list<>::insert_after(const_iterator, const _Tp&), (forward_list<>::insert_after(const_iterator, const _Tp&),
......
...@@ -469,7 +469,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -469,7 +469,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
iterator __first = begin(); iterator __first = begin();
iterator __last = end(); iterator __last = end();
if (__first == __last) if (__first == __last)
return; return;
iterator __next = __first; iterator __next = __first;
while (++__next != __last) while (++__next != __last)
{ {
...@@ -518,10 +518,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -518,10 +518,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
{ {
// We don't have size() so we need to walk through both lists // We don't have size() so we need to walk through both lists
// making sure both iterators are valid. // making sure both iterators are valid.
typename std::forward_list<_Tp, _Alloc>::const_iterator __ix auto __ix = __lx.cbegin();
= __lx.cbegin(); auto __iy = __ly.cbegin();
typename std::forward_list<_Tp, _Alloc>::const_iterator __iy
= __ly.cbegin();
while (__ix != __lx.cend() && __iy != __ly.cend()) while (__ix != __lx.cend() && __iy != __ly.cend())
{ {
if (*__ix != *__iy) if (*__ix != *__iy)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment