[Python-checkins] r45668 - python/trunk/Doc/tut/tut.tex

nick.coghlan python-checkins at python.org
Sun Apr 23 18:35:20 CEST 2006


Author: nick.coghlan
Date: Sun Apr 23 18:35:19 2006
New Revision: 45668

Modified:
   python/trunk/Doc/tut/tut.tex
Log:
Take 2 on mentioning the with statement, this time without inadvertently killing the Unicode examples

Modified: python/trunk/Doc/tut/tut.tex
==============================================================================
--- python/trunk/Doc/tut/tut.tex	(original)
+++ python/trunk/Doc/tut/tut.tex	Sun Apr 23 18:35:19 2006
@@ -941,9 +941,9 @@
 u'abc'
 >>> str(u"abc")
 'abc'
->>> u"�"
+>>> u"äöü"
 u'\xe4\xf6\xfc'
->>> str(u"�")
+>>> str(u"äöü")
 Traceback (most recent call last):
   File "<stdin>", line 1, in ?
 UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-2: ordinal not in range(128)
@@ -955,7 +955,7 @@
 for encodings are preferred.
 
 \begin{verbatim}
->>> u"�".encode('utf-8')
+>>> u"äöü".encode('utf-8')
 '\xc3\xa4\xc3\xb6\xc3\xbc'
 \end{verbatim}
 
@@ -3744,6 +3744,7 @@
 for releasing external resources (such as files or network connections),
 regardless of whether the use of the resource was successful.
 
+
 \section{Predefined Clean-up Actions \label{cleanup-with}}
 
 Some objects define standard clean-up actions to be undertaken when
@@ -3775,6 +3776,7 @@
 objects which provide predefined clean-up actions will indicate
 this in their documentation.
 
+
 \chapter{Classes \label{classes}}
 
 Python's class mechanism adds classes to the language with a minimum


More information about the Python-checkins mailing list