From 6bfcbf0d48e8e9e71abb7302f677ab5bd32286e0 Mon Sep 17 00:00:00 2001 From: Nathan Myers Date: Thu, 25 Jan 2007 13:08:51 +0000 Subject: [PATCH] streambuf_iterator.h (istreambuf_iterator<>::equal): Simplify. 2007-01-25 Nathan Myers * include/bits/streambuf_iterator.h (istreambuf_iterator<>::equal): Simplify. From-SVN: r121170 --- libstdc++-v3/ChangeLog | 5 +++++ libstdc++-v3/include/bits/streambuf_iterator.h | 6 +----- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index bcc3056..24034fa 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2007-01-25 Nathan Myers + + * include/bits/streambuf_iterator.h (istreambuf_iterator<>::equal): + Simplify. + 2007-01-24 Steve LoBasso Paolo Carlini diff --git a/libstdc++-v3/include/bits/streambuf_iterator.h b/libstdc++-v3/include/bits/streambuf_iterator.h index c743bb3..26cc00f 100644 --- a/libstdc++-v3/include/bits/streambuf_iterator.h +++ b/libstdc++-v3/include/bits/streambuf_iterator.h @@ -157,11 +157,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) /// Return true both iterators are end or both are not end. bool equal(const istreambuf_iterator& __b) const - { - const bool __thiseof = _M_at_eof(); - const bool __beof = __b._M_at_eof(); - return ((__thiseof && __beof) || (!__thiseof && !__beof)); - } + { return _M_at_eof() == __b._M_at_eof(); } private: int_type -- 2.7.4