From: Benjamin Kosnik Date: Sat, 18 May 2002 14:37:49 +0000 (+0000) Subject: 2002-05-18 Benjamin Kosnik X-Git-Tag: releases/gcc-3.1.1~334 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aca44fd38c8f122a404a8412186dbc6fbe8e7e93;p=thirdparty%2Fgcc.git 2002-05-18 Benjamin Kosnik * include/bits/fstream.tcc (basic_filebuf::_M_allocate_internal_buffer): Remove extraneous try/catch blocks. * src/localename.cc (locale::_Impl::_M_install_facet): Same. * docs/html/install.html: Tweak, add bits about required locales for the 22_locale tests when using the gnu model. * testsuite/27_io/istream_sentry.cc: Tweak. From-SVN: r53583 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 8c9169457d64..f31037f54c88 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,15 @@ +2002-05-18 Benjamin Kosnik + + * include/bits/fstream.tcc + (basic_filebuf::_M_allocate_internal_buffer): Remove extraneous + try/catch blocks. + * src/localename.cc (locale::_Impl::_M_install_facet): Same. + + * docs/html/install.html: Tweak, add bits about required locales + for the 22_locale tests when using the gnu model. + + * testsuite/27_io/istream_sentry.cc: Tweak. + 2002-05-16 Phil Edwards * docs/html/faq/index.html: Update not-a-bug list with basic_file.h. diff --git a/libstdc++-v3/docs/html/install.html b/libstdc++-v3/docs/html/install.html index dce85f02d697..c2ec0305a9d9 100644 --- a/libstdc++-v3/docs/html/install.html +++ b/libstdc++-v3/docs/html/install.html @@ -67,32 +67,57 @@

As of June 19, 2000, libstdc++ attempts to use tricky and space-saving features of the GNU toolchain, enabled with - -ffunction-sections -fdata-sections -Wl,--gc-sections. - To obtain maximum benefit from this, binutils after this date - should also be used (bugs were fixed with C++ exception handling - related to this change in libstdc++-v3). The version of these - tools should be 2.10.90, and you can get snapshots (as - well as releases) of binutils - here. + -ffunction-sections -fdata-sections + -Wl,--gc-sections. To obtain maximum benefit from this, + binutils after this date should also be used (bugs were fixed + with C++ exception handling related to this change in + libstdc++-v3). The version of these tools should be + 2.10.90, or later, and you can get snapshots (as + well as releases) of binutils + here. The + configure process will automatically detect and use these + features if the underlying support is present.

If you are using a 3.1-series libstdc++ snapshot, then the - requirements are slightly more stringent: the compiler sources must - also be 3.1 or later (for both technical and licensing reasons), and - your binutils must be 2.11.95 or later if you want to use symbol - versioning in shared libraries. + requirements are slightly more stringent: the compiler sources + must also be 3.1 or later (for both technical and licensing + reasons), and your binutils must be 2.11.95 or later if you want + to use symbol versioning in shared libraries. Again, the + configure process will automatically detect and use these + features if the underlying support is present.

-
diff --git a/libstdc++-v3/include/bits/fstream.tcc b/libstdc++-v3/include/bits/fstream.tcc index 90850f54f0d7..5b7e8bf9eaed 100644 --- a/libstdc++-v3/include/bits/fstream.tcc +++ b/libstdc++-v3/include/bits/fstream.tcc @@ -49,12 +49,7 @@ namespace std _M_buf_size = _M_buf_size_opt; // Allocate internal buffer. - try { _M_buf = new char_type[_M_buf_size]; } - catch(...) - { - delete [] _M_buf; - __throw_exception_again; - } + _M_buf = new char_type[_M_buf_size]; _M_buf_allocated = true; } } diff --git a/libstdc++-v3/src/localename.cc b/libstdc++-v3/src/localename.cc index 1b40e0c3db66..824d9790cef9 100644 --- a/libstdc++-v3/src/localename.cc +++ b/libstdc++-v3/src/localename.cc @@ -255,13 +255,7 @@ namespace std facet** __old = _M_facets; facet** __new; const size_t __new_size = __index + 4; - try - { __new = new facet*[__new_size]; } - catch(...) - { - delete [] __new; - __throw_exception_again; - } + __new = new facet*[__new_size]; for (size_t __i = 0; __i < _M_facets_size; ++__i) __new[__i] = _M_facets[__i]; for (size_t __i2 = _M_facets_size; __i2 < __new_size; ++__i2) diff --git a/libstdc++-v3/testsuite/27_io/istream_sentry.cc b/libstdc++-v3/testsuite/27_io/istream_sentry.cc index 88dcb91df248..8ff446f09fc2 100644 --- a/libstdc++-v3/testsuite/27_io/istream_sentry.cc +++ b/libstdc++-v3/testsuite/27_io/istream_sentry.cc @@ -70,7 +70,7 @@ test02() double x; // ios_base::eof == 2 - while(in >> x) + while (in >> x) { ++i; if (i > 3)