From: Raymond Hettinger Date: Mon, 13 Jan 2003 04:33:36 +0000 (+0000) Subject: SF patch 664183 and SF bug 664044: Note that both u'%s' % 'x' and X-Git-Tag: v2.2.3c1~176 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4e1734642223eed2a0b9be26a3bb79b216d26ca6;p=thirdparty%2FPython%2Fcpython.git SF patch 664183 and SF bug 664044: Note that both u'%s' % 'x' and '%s' % u'x' return a unicode object. --- diff --git a/Doc/lib/libstdtypes.tex b/Doc/lib/libstdtypes.tex index 9a6006a5287e..4c4b7218e1cf 100644 --- a/Doc/lib/libstdtypes.tex +++ b/Doc/lib/libstdtypes.tex @@ -826,7 +826,7 @@ The conversion types are: \lineiii{r}{String (converts any python object using \function{repr()}).}{(3)} \lineiii{s}{String (converts any python object using - \function{str()}).}{} + \function{str()}).}{(4)} \lineiii{\%}{No argument is converted, results in a \character{\%} character in the result.}{} \end{tableiii} @@ -847,6 +847,9 @@ Notes: not already a zero. \item[(3)] The \code{\%r} conversion was added in Python 2.0. + \item[(4)] + If the object or format provided is a \class{unicode} string, + the resulting string will also be \class{unicode}. \end{description} % XXX Examples?