This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
[libstdc++] prepass filter for doxygen, update links
- From: Phil Edwards <phil at jaj dot com>
- To: libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Fri, 30 May 2003 15:13:04 -0400
- Subject: [libstdc++] prepass filter for doxygen, update links
Benjamin pointed out to me that the links to the online doxygen pages
hadn't been updated to point to the new releases; fixed here.
This also adds some semi-sloppy hooks for preprocessing the library when
running doxygen, to remove leading underscores and in general choose more
readable names. Little things like seeing
std::vector<Type>
instead of
std::vector<_Tp>
have a surprising (to me anyway) positive effect on readability.
2003-05-30 Phil Edwards <pme@gcc.gnu.org>
* docs/doxygen/filter: New file.
* docs/doxygen/filter.sed: New file.
* docs/doxygen/run_doxygen: Add g flag to sed substitutions. Duh.
* docs/doxygen/user.cfg.in (INPUT_FILTER): Point to new filter.
* docs/html/documentation.html: Fix links to doxygen pages.
Index: docs/doxygen/filter
===================================================================
RCS file: docs/doxygen/filter
diff -N docs/doxygen/filter
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ docs/doxygen/filter 30 May 2003 19:07:47 -0000
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+script=$1
+file=$2
+
+# Possibly allow some files to go unchanged. Other
+# future manipulations are likely.
+case $file in
+ */alloc_policies.h)
+ cat $file ;;
+ *) sed -f $script $file ;;
+esac
+
Index: docs/doxygen/filter.sed
===================================================================
RCS file: docs/doxygen/filter.sed
diff -N docs/doxygen/filter.sed
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ docs/doxygen/filter.sed 30 May 2003 19:07:47 -0000
@@ -0,0 +1,26 @@
+# Input filter for doxygen.
+# Copyright (C) 2003 Free Software Foundation, Inc.
+# Phil Edwards <pme@gcc.gnu.org>
+
+# single+capital is easy
+s/_Tp/Type/g
+s/_\([A-Z]\)/\1/g
+
+# double+lower is not so easy; some names should be left alone.
+# The following is a sloppy start. Possibly just require GNU tools
+# and use extensions.
+s/__a/a/g
+s/__c/c/g
+s/__first/first/g
+s/__in/in/g
+s/__last/last/g
+s/__n/n/g
+s/__out/out/g
+s/__pred/pred/g
+s/__position/position/g
+s/__pos/position/g
+s/__s/s/g
+s/__value/value/g
+s/__x/x/g
+s/__y/y/g
+
Index: docs/doxygen/run_doxygen
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/doxygen/run_doxygen,v
retrieving revision 1.21
diff -u -3 -p -r1.21 run_doxygen
--- docs/doxygen/run_doxygen 29 Apr 2003 23:48:52 -0000 1.21
+++ docs/doxygen/run_doxygen 30 May 2003 19:07:47 -0000
@@ -134,8 +134,8 @@ test $do_man = yes && {
(
set -e
cd $builddir
- sed -e "s=@outdir@=${outdir}=" \
- -e "s=@srcdir@=${srcdir}=" \
+ sed -e "s=@outdir@=${outdir}=g" \
+ -e "s=@srcdir@=${srcdir}=g" \
-e "s=@html_output_dir@=html_${mode}=" \
-e "s=@enabled_sections@=${enabled_sections}=" \
-e "s=@do_html@=${do_html}=" \
Index: docs/doxygen/user.cfg.in
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/doxygen/user.cfg.in,v
retrieving revision 1.24
diff -u -3 -p -r1.24 user.cfg.in
--- docs/doxygen/user.cfg.in 29 Apr 2003 23:48:52 -0000 1.24
+++ docs/doxygen/user.cfg.in 30 May 2003 19:07:47 -0000
@@ -384,6 +384,7 @@ RECURSIVE = YES
EXCLUDE = Makefile \
CVS \
+ include/bits/demangle.h \
stdc++.h.gch
# The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories
@@ -433,7 +434,7 @@ IMAGE_PATH =
# input file. Doxygen will then use the output that the filter program writes
# to standard output.
-INPUT_FILTER =
+INPUT_FILTER = "@srcdir@/docs/doxygen/filter @srcdir@/docs/doxygen/filter.sed"
# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using
# INPUT_FILTER) will be used to filter the input files when producing source
@@ -459,7 +460,7 @@ INLINE_SOURCES = NO
# doxygen to hide any special comment blocks from generated source code
# fragments. Normal C and C++ comments will always remain visible.
-STRIP_CODE_COMMENTS = YES
+STRIP_CODE_COMMENTS = NO
# If the REFERENCED_BY_RELATION tag is set to YES (the default)
# then for each documented function all documented
Index: docs/html/documentation.html
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/docs/html/documentation.html,v
retrieving revision 1.33
diff -u -3 -p -r1.33 documentation.html
--- docs/html/documentation.html 20 May 2003 22:25:08 -0000 1.33
+++ docs/html/documentation.html 30 May 2003 19:07:47 -0000
@@ -67,24 +67,25 @@
the library classes, finding out what is in a particular include
file, looking at inheritance diagrams, etc.
</p>
-<p>The Source-Level documentation can be viewed online:</p>
+<p>The source-level documentation for the most recent releases can
+ be viewed online:
+</p>
<ul>
- <li><a href="libstdc++-html-USERS-3.1/index.html">for the 3.1 release</a>
- </li>
- <li><a href="libstdc++-html-USERS-3.2.1/index.html">for the 3.2.1 release</a>
- </li>
- <li><a href="latest-doxygen/index.html">"the latest collection"</a>
- (for the snapshot or later; see the date on the first page)
- </li>
+ <li><a href="libstdc++-html-USERS-3.3/index.html">for the 3.3 release</a></li>
+ <li><a href="latest-doxygen/index.html">"the latest collection"</a>
+ (for the main development tree; see the date on the first page)
+ </li>
</ul>
<p>This generated HTML collection, as above, is also available for download in
the libstdc++ snapshots directory at
<code><URL:ftp://gcc.gnu.org/pub/gcc/libstdc++/doxygen/></code>.
- You will almost certainly need to use one of the <a
- href="http://gcc.gnu.org/mirrors.html">mirror sites</a> to download
- the tarball. After unpacking, simply load
- libstdc++-html-*/index.html into a browser. Feedback (and
- additional documentation!) is welcome.
+ You will almost certainly need to use one of the
+ <a href="http://gcc.gnu.org/mirrors.html">mirror sites</a> to download
+ the tarball. After unpacking, simply load libstdc++-html-*/index.html
+ into a browser.
+</p>
+<p>Documentation for older releases is available for download only, not
+ online viewing.
</p>
<p>In addition, an initial set of man pages are also available in the
same place as the HTML collections. Start with C++Intro(3).