From: Paolo Carlini Date: Tue, 10 Dec 2013 09:48:50 +0000 (+0000) Subject: value.cc: Add test. X-Git-Tag: releases/gcc-4.9.0~2168 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a0d026d943dc202a52dbbe144064ad7ec08180b0;p=thirdparty%2Fgcc.git value.cc: Add test. 2013-12-10 Paolo Carlini * testsuite/20_util/is_base_of/value.cc: Add test. * include/std/fstream: Tiny formatting tweak. From-SVN: r205851 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index a9f6075897b0..11132fe73199 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2013-12-10 Paolo Carlini + + * testsuite/20_util/is_base_of/value.cc: Add test. + + * include/std/fstream: Tiny formatting tweak. + 2013-12-09 Paolo Carlini PR libstdc++/59427 diff --git a/libstdc++-v3/include/std/fstream b/libstdc++-v3/include/std/fstream index ce27eb61a080..4bebdb1cc7b9 100644 --- a/libstdc++-v3/include/std/fstream +++ b/libstdc++-v3/include/std/fstream @@ -396,8 +396,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION void _M_set_buffer(streamsize __off) { - const bool __testin = _M_mode & ios_base::in; - const bool __testout = (_M_mode & ios_base::out + const bool __testin = _M_mode & ios_base::in; + const bool __testout = (_M_mode & ios_base::out || _M_mode & ios_base::app); if (__testin && __off > 0) diff --git a/libstdc++-v3/testsuite/20_util/is_base_of/value.cc b/libstdc++-v3/testsuite/20_util/is_base_of/value.cc index cacee4c5dee8..7a8840301e5b 100644 --- a/libstdc++-v3/testsuite/20_util/is_base_of/value.cc +++ b/libstdc++-v3/testsuite/20_util/is_base_of/value.cc @@ -47,6 +47,8 @@ void test01() using namespace __gnu_test; // Positive tests. + static_assert(test_relationship(true), ""); static_assert(test_relationship(true), ""); static_assert(test_relationship