[Python-checkins] python/dist/src/Doc/lib libstdtypes.tex, 1.156, 1.157

doerwalter at users.sourceforge.net doerwalter at users.sourceforge.net
Thu Jul 1 15:58:50 EDT 2004


Update of /cvsroot/python/python/dist/src/Doc/lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5364

Modified Files:
	libstdtypes.tex 
Log Message:
Document that encode() and decode() raise UnicodeError
instead of ValueError.

Add a note about error handling schemes added by PEP 293.


Index: libstdtypes.tex
===================================================================
RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.156
retrieving revision 1.157
diff -C2 -d -r1.156 -r1.157
*** libstdtypes.tex	1 Jul 2004 19:26:04 -0000	1.156
--- libstdtypes.tex	1 Jul 2004 19:58:47 -0000	1.157
***************
*** 568,574 ****
  may be given to set a different error handling scheme.  The default is
  \code{'strict'}, meaning that encoding errors raise
! \exception{ValueError}.  Other possible values are \code{'ignore'} and
! \code{'replace'}.
  \versionadded{2.2}
  \end{methoddesc}
  
--- 568,576 ----
  may be given to set a different error handling scheme.  The default is
  \code{'strict'}, meaning that encoding errors raise
! \exception{UnicodeError}.  Other possible values are \code{'ignore'},
! \code{'replace'} and any other name registered via
! \function{codecs.register_error}.
  \versionadded{2.2}
+ \versionchanged[Support for other error handling schemes added]{2.3}
  \end{methoddesc}
  
***************
*** 578,585 ****
  error handling scheme.  The default for \var{errors} is
  \code{'strict'}, meaning that encoding errors raise a
! \exception{ValueError}.  Other possible values are \code{'ignore'} and
! \code{'replace'}.  For a list of possible encodings, see
! section~\ref{standard-encodings}.
  \versionadded{2.0}
  \end{methoddesc}
  
--- 580,590 ----
  error handling scheme.  The default for \var{errors} is
  \code{'strict'}, meaning that encoding errors raise a
! \exception{UnicodeError}.  Other possible values are \code{'ignore'},
! \code{'replace'}, \code{'xmlcharrefreplace'}, \code{'backslashreplace'}
! and any other name registered via \function{codecs.register_error}.
! For a list of possible encodings, see section~\ref{standard-encodings}.
  \versionadded{2.0}
+ \versionchanged[Support for \code{'xmlcharrefreplace'} and
+ \code{'backslashreplace'} and other error handling schemes added]{2.3}
  \end{methoddesc}
  




More information about the Python-checkins mailing list