This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[libstdc++] General cleanups and updates



These are just typo fixes, sanity updates, and documentation updates (e.g.,
the locale-related files were including <memory> "for auto_ptr" but didn't
use auto_ptr nor anything else from that header).

Tested on i686-linux (and sparc-solaris8 when it bootstraps) over the past
several days.  Committed to trunk.


2002-03-06  Phil Edwards  <pme@gcc.gnu.org>

	* docs/doxygen/user.cfg.in:  Also document deprecated entries.
	* docs/html/Makefile:  Example rule to rebuild porting-howto.html.
	* docs/html/17_intro/howto.html:  "gcc"->"GCC" changes, when
	referring to the collection as a whole.  New section on which macros
	can be redefined by the user.
	* docs/html/19_diagnostics/howto.html:  Update note for concepts.
	* docs/html/20_util/howto.html:  Update link to SGI.
	* docs/html/faq/index.html:  Update snapshot versions.  New entry
	on why g++ (but not gcc) must currently predefine certain macros.
	* docs/html/faq/index.txt:  Regenerated.

	* include/bits/basic_string.h (basic_string::_S_construct):  Fix
	names in declaration.
	(basic_string::compare):  These are no longer optional.
	* include/bits/ostream.tcc:  Tweak closing brace placement.
	* include/bits/stl_algo.h:  Lots of initial doxygen comment hooks.
	* include/std/std_sstream.h:  Fix typo in comment.
	* include/bits/locale_facets.tcc:  Remove unneeded header inclusion.
	* src/locale.cc:  Likewise.


Index: docs/doxygen/user.cfg.in
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/doxygen/user.cfg.in,v
retrieving revision 1.14
diff -u -3 -p -r1.14 user.cfg.in
--- user.cfg.in	2002/02/08 07:34:53	1.14
+++ user.cfg.in	2002/03/06 21:15:13
@@ -703,7 +703,7 @@ INCLUDE_FILE_PATTERNS  = 
 # or name=definition (no spaces). If the definition and the = are 
 # omitted =1 is assumed.
 
-PREDEFINED             = 
+PREDEFINED             = _GLIBCPP_DEPRECATED
 
 # If the MACRO_EXPANSION and EXPAND_PREDEF_ONLY tags are set to YES then 
 # this tag can be used to specify a list of macro names that should be expanded. 
Index: docs/html/Makefile
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/Makefile,v
retrieving revision 1.2
diff -u -3 -p -r1.2 Makefile
--- Makefile	2001/11/06 00:18:37	1.2
+++ Makefile	2002/03/06 21:15:13
@@ -2,7 +2,7 @@
 MAKEINFO=makeinfo
 INC=../../../gcc/doc/include
 
-all: faq/index.txt 17_intro/porting.html
+all: faq/index.txt 17_intro/porting.html 17_intro/porting-howto.html
 
 
 faq/index.txt: faq/index.html
@@ -10,4 +10,8 @@ faq/index.txt: faq/index.html
 
 17_intro/porting.html: 17_intro/porting.texi
 	${MAKEINFO} -I ${INC} --html --no-split $< -o $@
+
+# known to work under RH; this can be cleaned up later if needed
+17_intro/porting-howto.html: 17_intro/porting-howto.xml
+	xltproc -o $@ /usr/share/xml/docbook/xsl-stylesheets-1.48-2/html/docbook.xsl $<
 
Index: docs/html/17_intro/howto.html
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/17_intro/howto.html,v
retrieving revision 1.20
diff -u -3 -p -r1.20 howto.html
--- howto.html	2002/02/05 00:14:36	1.20
+++ howto.html	2002/03/06 21:15:13
@@ -29,6 +29,7 @@
    <li><a href="#4"><code>&lt;foo&gt;</code> vs <code>&lt;foo.h&gt;</code></a>
    <li><a href="porting-howto.html">Porting HOWTO</a>
    <li><a href="#5">Behavior specific to libstdc++-v3</a>
+   <li><a href="#6">Preprocessor macros controlling the library</a>
 </ul>
 
 <hr>
@@ -54,20 +55,20 @@
 <h2><a name="3">The Standard C++ library and multithreading</a></h2>
    <p>This section discusses issues surrounding the proper compilation
       of multithreaded applications which use the Standard C++
-      library.  This information is gcc-specific since the C++
+      library.  This information is GCC-specific since the C++
       standard does not address matters of multithreaded applications.
       Unless explicitly prefaced, all information in this section is
-      current as of the gcc 3.0 release and all later point releases.
+      current as of the GCC 3.0 release and all later point releases.
    </p>
-   <p>Earlier gcc releases had a somewhat different approach to
-      threading configuration and proper compilation.  Before gcc 3.0,
+   <p>Earlier GCC releases had a somewhat different approach to
+      threading configuration and proper compilation.  Before GCC 3.0,
       configuration of the threading model was dictated by compiler
       command-line options and macros (both of which were somewhat
       thread-implementation and port-specific).  There were no
       guarantees related to being able to link code compiled with one
-      set of options and macro setting with another set.  For gcc 3.0,
+      set of options and macro setting with another set.  For GCC 3.0,
       configuration of the threading model used with libraries and
-      user-code is performed when gcc is configured and built using
+      user-code is performed when GCC is configured and built using
       the --enable-threads and --disable-threads options.  The ABI is
       stable for symbol name-mangling and limited functional
       compatibility exists between code compiled under different
@@ -83,9 +84,9 @@
       with another thread model useful on the platform.  Other mixes
       may or may not work but are not considered supported.  (Thus, if
       you distribute a shared C++ library in binary form only, it may
-      be best to compile it with a gcc configured with
+      be best to compile it with a GCC configured with
       --enable-threads for maximal interchangeability and usefulness
-      with a user population that may have built gcc with either
+      with a user population that may have built GCC with either
       --enable-threads or --disable-threads.)
    </p>
    <p>When you link a multithreaded application, you will probably
@@ -262,6 +263,71 @@
    </p>
    <p><strong>[27.8.1.4]/16</strong> Calling <code>fstream::sync</code> when
       a get area exists will... whatever <code>fflush()</code> does, I think.
+   </p>
+   <p>Return <a href="#top">to top of page</a> or
+      <a href="../faq/index.html">to the FAQ</a>.
+   </p>
+
+<hr>
+<h2><a name="6">Preprocessor macros controlling the library</a></h2>
+   <p>Some of the semantics of the libstdc++-v3 implementation are
+      controlled by preprocessor macros, both during build/installation and
+      during compilation of user code.  Many of these choices are made when
+      the library is built and installed (actually, during
+      <a href="../configopts.html">the configuration step</a>, with the
+      various --enable/--disable choices being translated to #define/#undef).
+   </p>
+   <p>All library macros begin with <code>_GLIBCPP_</code>.  The fact that
+      these symbols start with a leading underscore should give you a clue
+      that (by default) they aren't meant to be changed by the user.  :-)
+   </p>
+   <p>These macros are all gathered in the file <code>c++config.h</code>,
+      which is generated during installation.  <strong>You must assume that
+      these macros cannot be redefined by your own code</strong>, unless we
+      document otherwise here.  Some of the choices control code which has
+      already been compiled (i.e., libstdc++.a/.so).  If you explicitly
+      #define or #undef these macros, the <em>headers</em> may see different
+      code paths, but the <em>libraries</em> which you link against will not.
+      If you want to experiment with different values, you must change the
+      config headers before building/installing the library.
+   </p>
+   <p>Below are macros which, for 3.1 and later, you may change yourself,
+      in your own code with #define/#undef or with -D/-U compiler flags.
+      The default state of the symbol is listed.  &quot;Configurable&quot;
+      (or &quot;Not configurable&quot;) means that the symbol is initially
+      chosen (or not) based on --enable/--disable options at configure time.
+    <dl>
+    <dt><code>_GLIBCPP_DEPRECATED</code></dt>
+    <dd>Undefined by default.  Not configurable.  Turning this on enables
+        older ARM-style iostreams code, and other anachronisms.  This may be
+        useful in updating old C++ programs which no longer meet the
+        requirements of the language.
+    </dd>
+    <!--
+     Can this actually be turned off and still produce a working lib?  Must
+     check.  -pme
+     No, it can't.  Hmmm.  -pme
+    <dt><code>_GLIBCPP_RESOLVE_LIB_DEFECTS</code></dt>
+    <dd>Defined by default.  Not configurable.  The library follows
+        corrections and updates from the ISO committee, see
+        <a href="../faq/index.html#5_2">here</a> and
+        <a href="../ext/howto.html#5">here</a> for more on this feature.
+        If you have code which depends on the first version of the standard,
+        you might try undefining this macro.
+    </dd>
+    -->
+    <dt><code>_GLIBCPP_CONCEPT_CHECKS</code></dt>
+    <dd>Undefined by default.  Configurable.  When defined, performs
+        compile-time checking on certain template instantiations to detect
+        violations of the requirements of the standard.  This is described
+        in more detail <a href="../19_diagnostics/howto.html#3">here</a>.
+    </dd>
+    <!--
+    <dt><code></code></dt>
+    <dd>
+    </dd>
+    -->
+    </dl>
    </p>
    <p>Return <a href="#top">to top of page</a> or
       <a href="../faq/index.html">to the FAQ</a>.
Index: docs/html/19_diagnostics/howto.html
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/19_diagnostics/howto.html,v
retrieving revision 1.14
diff -u -3 -p -r1.14 howto.html
--- howto.html	2002/01/28 22:13:04	1.14
+++ howto.html	2002/03/06 21:15:13
@@ -102,6 +102,8 @@
    <p>For GCC 3.0 and 3.1 they are off by default.  They can be enabled at
       configure time with
       <a href="../configopts.html"><code>--enable-concept-checks</code></a>.
+      For 3.1 you can instead #define _GLIBCPP_CONCEPT_CHECKS to enable them
+      on a per-translation-unit basis.
    </p>
    <p>Return <a href="#top">to top of page</a> or
       <a href="../faq/index.html">to the FAQ</a>.
Index: docs/html/20_util/howto.html
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/20_util/howto.html,v
retrieving revision 1.12
diff -u -3 -p -r1.12 howto.html
--- howto.html	2001/11/23 16:29:00	1.12
+++ howto.html	2002/03/06 21:15:13
@@ -134,8 +134,8 @@
       get slightly the wrong idea.  In the interest of not reinventing
       the wheel, we will refer you to the introduction to the functor
       concept written by SGI as part of their STL, in
-      <a href="http://www.sgi.com/Technology/STL/functors.html";>their
-      http://www.sgi.com/Technology/STL/functors.html</a>.
+      <a href="http://www.sgi.com/tech/stl/functors.html";>their
+      http://www.sgi.com/tech/stl/functors.html</a>.
    </p>
    <p>Return <a href="#top">to top of page</a> or
       <a href="../faq/index.html">to the FAQ</a>.
Index: docs/html/faq/index.html
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/faq/index.html,v
retrieving revision 1.31
diff -u -3 -p -r1.31 index.html
--- index.html	2002/02/25 05:24:53	1.31
+++ index.html	2002/03/06 21:15:14
@@ -59,6 +59,8 @@
          <li><a href="#3_2">[removed]</a>
          <li><a href="#3_3">[removed]</a>
          <li><a href="#3_4">I can't use 'long long' on Solaris</a>
+         <li><a href="#3_5"><code>_XOPEN_SOURCE</code> /
+                            <code>_GNU_SOURCE</code> / etc is always defined</a>
       </ol>
 
    <li><a href="#4_0">Known Bugs and Non-Bugs</a>
@@ -109,7 +111,7 @@
          library reaches stable plateaus, it is captured in a snapshot
          and released.  The current release is
          <a href="http://gcc.gnu.org/libstdc++/download.html";>the
-         thirteenth snapshot</a>.  For those who want to see exactly how
+         fourteenth snapshot</a>.  For those who want to see exactly how
          far the project has come, or just want the latest
          bleeding-edge code, the up-to-date source is available over
          anonymous CVS, and can even be browsed over the Web (see below). 
@@ -165,7 +167,7 @@
 
 <hr>
    <h2><a name="1_4">1.4 How do I get libstdc++?</a></h2>
-      <p>The thirteenth (and latest) snapshot of libstdc++-v3 is
+      <p>The fourteenth (and latest) snapshot of libstdc++-v3 is
          <a href="http://gcc.gnu.org/libstdc++/download.html";>available via
          ftp</a>.
       </p>
@@ -429,6 +431,44 @@ which is no longer available, thanks dej
       </p>
 
 <hr>
+   <h2><a name="3_5">3.5 <code>_XOPEN_SOURCE</code> / <code>_GNU_SOURCE</code>
+                         / etc is always defined</a></h2>
+      <p>On Solaris, g++ (but not gcc) always defines the preprocessor
+         macro <code>_XOPEN_SOURCE</code>.  On GNU/Linux, the same happens
+         with <code>_GNU_SOURCE</code>.  (This is not an exhaustive list;
+         other macros and other platforms are also affected.)
+      </p>
+      <p>These macros are typically used in C library headers, guarding new
+         versions of functions from their older versions.  The C++ standard
+         library includes the C standard library, but it requires the C90
+         version, which for backwards-compatability reasons is often not the
+         default for many vendors.
+      </p>
+      <p>More to the point, the C++ standard requires behavior which is only
+         available on certain platforms after certain symbols are defined.
+         Usually the issue involves I/O-related typedefs.  In order to
+         ensure correctness, the compiler simply predefines those symbols.
+      </p>
+      <p>Note that it's not enough to #define them only when the library is
+         being built (during installation).  Since we don't have an 'export'
+         keyword, much of the library exists as headers, which means that
+         the symbols must also be defined as your programs are parsed and
+         compiled.
+      </p>
+      <p>To see which symbols are defined, look for CPLUSPLUS_CPP_SPEC in
+         the gcc config headers for your target (and try changing them to
+         see what happens when building complicated code).  You can also run
+         <code>&quot;g++ -E -dM - &lt; /dev/null&quot;</code> to display
+         a list of predefined macros for any particular installation.
+      </p>
+      <p>This has been discussed on the mailing lists
+         <a href="http://gcc.gnu.org/cgi-bin/htsearch?method=and&format=builtin-long&sort=score&words=_XOPEN_SOURCE+Solaris";>quite a bit</a>.
+      </p>
+      <p>This method is something of a wart.  We'd like to find a cleaner
+         solution, but nobody yet has contributed the time.
+      </p>
+
+<hr>
 <h1><a name="4_0">4.0 Known Bugs and Non-Bugs</a></h1>
    <em>Note that this section can get rapdily outdated -- such is the
    nature of an open-source project.  For the latest information, join
@@ -462,39 +502,13 @@ which is no longer available, thanks dej
 <!-- Yeah, I meant that "verbatim clip" thing literally... :-)  -->
 
 <pre>
-New in 3.0.96:
+New in 3.0.97:
 ---
 - more doxygen documentation.
-- extensions moved out of namespace std
-- HPUX long long support
-- more string optimizations
-- support for NetBSD cross compiles
-- concept_check merge from boost
-- header simplification
-- named locale bug shakeout
-- thread testsuite
-
-New in 3.0.95:
----
-- add S390, m68k, x86-64 support.
-- doxygen documentation has been extended, including man pages.
-- verbose terminate handling has been added.
-- some libsupc++ tweaks
-- warnings for deprecated headers now active.
-- dejagnu testsuite preliminary documentation.
-- dejagnu testsuite default.
-- dejagnu testsuite cross compiler, multilib safe.
-- long long iostreams on by default, rework of ISO C99 support.
-- iterator re-write and testsuites.
-- container testsuites.
-- allocator revamp and testsuites.
-- more concept-checking work.
-- basic_string optimization and MT fixes.
-- new limits implementation.
-- update -fno-exceptions code, verify it works.
-- full named locale support fpr all facets, choice of gnu,
-  ieee_1003.1-200x (POSIX 2), or generic models. Full support depends
-  on target OS and underlying "C" library support.
+- more named locale bug fixes
+- support for symbol versioning when using GNU ld &gt;= 2.12
+- wide-io
+- tuning for executable size
 </pre>
 
 
Index: include/bits/basic_string.h
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/include/bits/basic_string.h,v
retrieving revision 1.19
diff -u -3 -p -r1.19 basic_string.h
--- basic_string.h	2002/02/12 04:35:56	1.19
+++ basic_string.h	2002/03/06 21:15:14
@@ -731,7 +731,7 @@ namespace std
       // string::iterator, _CharT*, etc.
       template<class _FwdIter>
         static _CharT*
-        _S_construct(_FwdIter __end, _FwdIter __beg, const _Alloc& __a,
+        _S_construct(_FwdIter __beg, _FwdIter __end, const _Alloc& __a,
 		     forward_iterator_tag);
 
       static _CharT* 
@@ -879,15 +879,14 @@ namespace std
       int 
       compare(const _CharT* __s) const;
 
-#ifdef _GLIBCPP_RESOLVE_LIB_DEFECTS
-// 5. String::compare specification questionable
+      // _GLIBCPP_RESOLVE_LIB_DEFECTS
+      // 5. String::compare specification questionable
       int 
       compare(size_type __pos, size_type __n1, const _CharT* __s) const;
 
       int 
       compare(size_type __pos, size_type __n1, const _CharT* __s, 
 	      size_type __n2) const;
-#endif
   };
 
 
Index: include/bits/locale_facets.tcc
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/include/bits/locale_facets.tcc,v
retrieving revision 1.66
diff -u -3 -p -r1.66 locale_facets.tcc
--- locale_facets.tcc	2002/03/05 12:09:42	1.66
+++ locale_facets.tcc	2002/03/06 21:15:14
@@ -41,7 +41,6 @@
 #include <cmath>     // For ceil
 #include <cctype>    // For isspace
 #include <limits>    // For numeric_limits
-#include <memory>    // For auto_ptr
 #include <bits/streambuf_iterator.h>
 #include <vector>	
 #include <typeinfo>  // For bad_cast.
Index: include/bits/ostream.tcc
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/include/bits/ostream.tcc,v
retrieving revision 1.22
diff -u -3 -p -r1.22 ostream.tcc
--- ostream.tcc	2002/02/16 19:33:43	1.22
+++ ostream.tcc	2002/03/06 21:15:14
@@ -464,8 +464,8 @@ namespace std 
 // 129. Need error indication from seekp() and seekg()
 	  if (__err == pos_type(off_type(-1)))
 	    this->setstate(ios_base::failbit);
-	}
 #endif
+	}
       return *this;
     }
 
Index: include/bits/stl_algo.h
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/include/bits/stl_algo.h,v
retrieving revision 1.22
diff -u -3 -p -r1.22 stl_algo.h
--- stl_algo.h	2002/02/12 04:35:56	1.22
+++ stl_algo.h	2002/03/06 21:15:14
@@ -120,7 +120,7 @@ namespace std
     __median(const _Tp& __a, const _Tp& __b, const _Tp& __c, _Compare __comp)
     {
       // concept requirements
-      __glibcpp_function_requires(_BinaryFunctionConcept<_Compare, bool, _Tp, _Tp>)
+      __glibcpp_function_requires(_BinaryFunctionConcept<_Compare,bool,_Tp,_Tp>)
       if (__comp(__a, __b))
 	if (__comp(__b, __c))
 	  return __b;
@@ -144,8 +144,7 @@ namespace std
    *  @return   @p f.
    *
    *  Applies the function object @p f to each element in the range
-   *  @p [first,last).
-   *  @p f must not modify its argument.
+   *  @p [first,last).  @p f must not modify the order of the sequence.
    *  If @p f has a return value it is ignored.
   */
   template<typename _InputIter, typename _Function>
@@ -1388,8 +1387,12 @@ __result, __binary_pred, _IterType());
       return __result;
     }
 
-  /// This is a helper function for the rotate algorithm specialized on RAIs.
 
+  /**
+   *  @maint
+   *  This is a helper function for the rotate algorithm specialized on RAIs.
+   *  @endmaint
+  */
   template<typename _EuclideanRingElement>
     _EuclideanRingElement
     __gcd(_EuclideanRingElement __m, _EuclideanRingElement __n)
@@ -1402,6 +1405,11 @@ __result, __binary_pred, _IterType());
       return __m;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the rotate algorithm.
+   *  @endmaint
+  */
   template<typename _ForwardIter>
     void
     __rotate(_ForwardIter __first,
@@ -1430,6 +1438,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the rotate algorithm.
+   *  @endmaint
+  */
   template<typename _BidirectionalIter>
     void
     __rotate(_BidirectionalIter __first,
@@ -1458,6 +1471,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the rotate algorithm.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter>
     void
     __rotate(_RandomAccessIter __first,
@@ -1519,6 +1537,15 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  middle  A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _ForwardIter>
     inline void
     rotate(_ForwardIter __first, _ForwardIter __middle, _ForwardIter __last)
@@ -1530,6 +1557,16 @@ __result, __binary_pred, _IterType());
       __rotate(__first, __middle, __last, _IterType());
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  middle  A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @param  result  An output iterator.
+   *  @return  TODO
+   *
+   *  @doctodo
+  */
   template<typename _ForwardIter, typename _OutputIter>
     _OutputIter
     rotate_copy(_ForwardIter __first, _ForwardIter __middle,
@@ -1542,10 +1579,17 @@ __result, __binary_pred, _IterType());
 
       return copy(__first, __middle, copy(__middle, __last, __result));
     }
+
 
-  // Return a random number in the range [0, __n).  This function encapsulates
-  // whether we're using rand (part of the standard C library) or lrand48
-  // (not standard, but a much better choice whenever it's available).
+  /**
+   *  @maint
+   *  Return a random number in the range [0, __n).  This function encapsulates
+   *  whether we're using rand (part of the standard C library) or lrand48
+   *  (not standard, but a much better choice whenever it's available).
+   *
+   *  XXX There is no corresponding encapsulation fn to seed the generator.
+   *  @endmaint
+  */
   template<typename _Distance>
     inline _Distance
     __random_number(_Distance __n)
@@ -1557,8 +1601,15 @@ __result, __binary_pred, _IterType());
   #endif
     }
 
-  /// 25.2.11 random_shuffle().
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter>
     inline void
     random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1572,6 +1623,15 @@ __result, __binary_pred, _IterType());
 	iter_swap(__i, __first + __random_number((__i - __first) + 1));
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @param  rand    The RNG functor or function.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter, typename _RandomNumberGenerator>
     void
     random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1586,8 +1646,12 @@ __result, __binary_pred, _IterType());
 	iter_swap(__i, __first + __rand((__i - __first) + 1));
     }
 
-  // partition, stable_partition, and their auxiliary functions
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _ForwardIter, typename _Predicate>
     _ForwardIter
     __partition(_ForwardIter __first, _ForwardIter __last,
@@ -1610,6 +1674,11 @@ __result, __binary_pred, _IterType());
       return __first;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _BidirectionalIter, typename _Predicate>
     _BidirectionalIter
     __partition(_BidirectionalIter __first, _BidirectionalIter __last,
@@ -1637,6 +1706,15 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @param  pred    A predicate functor.
+   *  @return  TODO
+   *
+   *  @doctodo
+  */
   template<typename _ForwardIter, typename _Predicate>
     inline _ForwardIter
     partition(_ForwardIter __first, _ForwardIter __last,
@@ -1651,6 +1729,11 @@ __result, __binary_pred, _IterType());
     }
 
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _ForwardIter, typename _Predicate, typename _Distance>
     _ForwardIter
     __inplace_stable_partition(_ForwardIter __first, _ForwardIter __last,
@@ -1671,6 +1754,11 @@ __result, __binary_pred, _IterType());
       return __begin;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _ForwardIter, typename _Pointer, typename _Predicate,
 	   typename _Distance>
     _ForwardIter
@@ -1711,6 +1799,15 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   A forward iterator.
+   *  @param  last    A forward iterator.
+   *  @param  pred    A predicate functor.
+   *  @return  TODO
+   *
+   *  @doctodo
+  */
   template<typename _ForwardIter, typename _Predicate>
     _ForwardIter
     stable_partition(_ForwardIter __first, _ForwardIter __last,
@@ -1739,6 +1836,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Tp>
     _RandomAccessIter
     __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1757,6 +1859,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function...
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Tp, typename _Compare>
     _RandomAccessIter
     __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1775,10 +1882,20 @@ __result, __binary_pred, _IterType());
       }
     }
 
-  extern const int __stl_threshold;
 
-  // sort() and its auxiliary functions.
+  /**
+   *  @maint
+   *  @doctodo
+   *  This controls some aspect of the sort routines.
+   *  @endmaint
+  */
+  extern const int __stl_threshold;
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Tp>
     void
     __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val)
@@ -1793,6 +1910,11 @@ __result, __binary_pred, _IterType());
       *__last = __val;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Tp, typename _Compare>
     void
     __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val, _Compare __comp)
@@ -1807,6 +1929,11 @@ __result, __binary_pred, _IterType());
       *__last = __val;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter>
     void
     __insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1825,6 +1952,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Compare>
     void
     __insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1844,6 +1976,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter>
     inline void
     __unguarded_insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1854,6 +1991,11 @@ __result, __binary_pred, _IterType());
 	__unguarded_linear_insert(__i, _ValueType(*__i));
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Compare>
     inline void
     __unguarded_insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1865,6 +2007,11 @@ __result, __binary_pred, _IterType());
 	__unguarded_linear_insert(__i, _ValueType(*__i), __comp);
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter>
     void
     __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1877,6 +2024,11 @@ __result, __binary_pred, _IterType());
 	__insertion_sort(__first, __last);
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Compare>
     void
     __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1890,6 +2042,11 @@ __result, __binary_pred, _IterType());
 	__insertion_sort(__first, __last, __comp);
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _Size>
     inline _Size
     __lg(_Size __n)
@@ -1899,6 +2056,11 @@ __result, __binary_pred, _IterType());
       return __k;
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Size>
     void
     __introsort_loop(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1922,6 +2084,11 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the sort routine.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Size, typename _Compare>
     void
     __introsort_loop(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -1946,6 +2113,14 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  last    Another iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter>
     inline void
     sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1963,6 +2138,15 @@ __result, __binary_pred, _IterType());
       }
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  last    Another iterator.
+   *  @param  comp    A comparison functor.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter, typename _Compare>
     inline void
     sort(_RandomAccessIter __first, _RandomAccessIter __last, _Compare __comp)
@@ -1980,8 +2164,12 @@ __result, __binary_pred, _IterType());
       }
     }
 
-  // stable_sort() and its auxiliary functions.
 
+  /**
+   *  @maint
+   *  This is a helper function for the stable sorting routines.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter>
     void
     __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -1998,6 +2186,11 @@ __result, __binary_pred, _IterType());
 			     __last - __middle);
     }
 
+  /**
+   *  @maint
+   *  This is a helper function for the stable sorting routines.
+   *  @endmaint
+  */
   template<typename _RandomAccessIter, typename _Compare>
     void
     __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter __last,
@@ -2171,6 +2364,14 @@ __result, __binary_pred, _IterType());
                        __comp);
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  last    Another iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter>
     inline void
     stable_sort(_RandomAccessIter __first, _RandomAccessIter __last)
@@ -2190,6 +2391,15 @@ __result, __binary_pred, _IterType());
 	__stable_sort_adaptive(__first, __last, buf.begin(), _DistanceType(buf.size()));
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  last    Another iterator.
+   *  @param  comp    A comparison functor.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter, typename _Compare>
     inline void
     stable_sort(_RandomAccessIter __first, _RandomAccessIter __last, _Compare __comp)
@@ -2211,6 +2421,15 @@ __result, __binary_pred, _IterType());
 			       __comp);
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  middle  Another iterator.
+   *  @param  last    Another iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter>
     void
     partial_sort(_RandomAccessIter __first,
@@ -2231,6 +2450,16 @@ __result, __binary_pred, _IterType());
       sort_heap(__first, __middle);
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  middle  Another iterator.
+   *  @param  last    Another iterator.
+   *  @param  comp    A comparison functor.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter, typename _Compare>
     void
     partial_sort(_RandomAccessIter __first,
@@ -2253,6 +2482,16 @@ __result, __binary_pred, _IterType());
       sort_heap(__first, __middle, __comp);
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An input iterator.
+   *  @param  last    Another input iterator.
+   *  @param  result_first   A random-access iterator.
+   *  @param  result_last    Another random-access iterator.
+   *  @return  TODO
+   *
+   *  @doctodo
+  */
   template<typename _InputIter, typename _RandomAccessIter>
     _RandomAccessIter
     partial_sort_copy(_InputIter __first, _InputIter __last,
@@ -2288,6 +2527,17 @@ __result, __binary_pred, _IterType());
       return __result_real_last;
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An input iterator.
+   *  @param  last    Another input iterator.
+   *  @param  result_first   A random-access iterator.
+   *  @param  result_last    Another random-access iterator.
+   *  @param  comp    A comparison functor.
+   *  @return  TODO
+   *
+   *  @doctodo
+  */
   template<typename _InputIter, typename _RandomAccessIter, typename _Compare>
     _RandomAccessIter
     partial_sort_copy(_InputIter __first, _InputIter __last,
@@ -2326,6 +2576,15 @@ __result, __binary_pred, _IterType());
       return __result_real_last;
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  nth     Another iterator.
+   *  @param  last    Another iterator.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter>
     void
     nth_element(_RandomAccessIter __first,
@@ -2352,6 +2611,16 @@ __result, __binary_pred, _IterType());
       __insertion_sort(__first, __last);
     }
 
+  /**
+   *  @brief TODO
+   *  @param  first   An iterator.
+   *  @param  nth     Another iterator.
+   *  @param  last    Another iterator.
+   *  @param  comp    A comparison functor.
+   *  @return  Nothing.
+   *
+   *  @doctodo
+  */
   template<typename _RandomAccessIter, typename _Compare>
     void
     nth_element(_RandomAccessIter __first,
Index: include/std/std_sstream.h
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/include/std/std_sstream.h,v
retrieving revision 1.5
diff -u -3 -p -r1.5 std_sstream.h
--- std_sstream.h	2002/03/03 17:48:41	1.5
+++ std_sstream.h	2002/03/06 21:15:15
@@ -124,7 +124,7 @@ namespace std
 	// NB: Start ostringstream buffers at 512 bytes. This is an
 	// experimental value (pronounced "arbitrary" in some of the
 	// hipper english-speaking countries), and can be changed to
-	// suite particular needs.
+	// suit particular needs.
 	_M_buf_size_opt = 512;
 	_M_mode = __mode;
 	if (_M_mode & (ios_base::ate | ios_base::app))
Index: src/locale.cc
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/src/locale.cc,v
retrieving revision 1.54
diff -u -3 -p -r1.54 locale.cc
--- locale.cc	2002/02/16 00:50:58	1.54
+++ locale.cc	2002/03/06 21:15:15
@@ -36,7 +36,6 @@
 #include <istream>
 #include <ostream>
 #include <vector>
-#include <memory>      // for auto_ptr
 #ifdef _GLIBCPP_USE_WCHAR_T  
 # include <cwctype>     // for towupper, etc.
 #endif


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]