[Python-checkins] cpython (3.2): Use source reST role instead of file where it makes sense.

eric.araujo python-checkins at python.org
Mon Mar 5 16:26:10 CET 2012


http://hg.python.org/cpython/rev/7894257ef861
changeset: 75424:7894257ef861
branch: 3.2
user: Éric Araujo <merwok at netwok.org>
date: Mon Mar 05 15:50:37 2012 +0100
summary:
 Use source reST role instead of file where it makes sense.
source generates a nifty link to the Mercurial web viewer.
files:
 Doc/howto/cporting.rst | 4 ++--
 Doc/howto/regex.rst | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Doc/howto/cporting.rst b/Doc/howto/cporting.rst
--- a/Doc/howto/cporting.rst
+++ b/Doc/howto/cporting.rst
@@ -261,8 +261,8 @@
 copy as you see fit.)
 
 You can find :file:`capsulethunk.h` in the Python source distribution
-in the :file:`Doc/includes` directory. We also include it here for
-your reference; here is :file:`capsulethunk.h`:
+as :source:`Doc/includes/capsulethunk.h`. We also include it here for
+your convenience:
 
 .. literalinclude:: ../includes/capsulethunk.h
 
diff --git a/Doc/howto/regex.rst b/Doc/howto/regex.rst
--- a/Doc/howto/regex.rst
+++ b/Doc/howto/regex.rst
@@ -360,7 +360,7 @@
 
 You can learn about this by interactively experimenting with the :mod:`re`
 module. If you have :mod:`tkinter` available, you may also want to look at
-:file:`Tools/demo/redemo.py`, a demonstration program included with the
+:source:`Tools/demo/redemo.py`, a demonstration program included with the
 Python distribution. It allows you to enter REs and strings, and displays
 whether the RE matches or fails. :file:`redemo.py` can be quite useful when
 trying to debug a complicated RE. Phil Schwartz's `Kodos
@@ -495,7 +495,7 @@
 the same ones in several locations, then it might be worthwhile to collect all
 the definitions in one place, in a section of code that compiles all the REs
 ahead of time. To take an example from the standard library, here's an extract
-from the now deprecated :file:`xmllib.py`::
+from the now-defunct Python 2 standard :mod:`xmllib` module::
 
 ref = re.compile( ... )
 entityref = re.compile( ... )
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /