From: A.M. K. <aku...@us...> - 2000-09-27 01:33:45
|
Update of /cvsroot/py-howto/pyhowto In directory slayer.i.sourceforge.net:/tmp/cvs-serv10632 Modified Files: python-2.0.tex Log Message: Wrote text for features added between 2.0b1 and b2. Minor rewrites, and added the CVS ID in a comment. Index: python-2.0.tex =================================================================== RCS file: /cvsroot/py-howto/pyhowto/python-2.0.tex,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -r1.31 -r1.32 *** python-2.0.tex 2000/09/27 01:01:18 1.31 --- python-2.0.tex 2000/09/27 01:33:41 1.32 *************** *** 1,4 **** --- 1,6 ---- \documentclass{howto} + % $Id$ + \title{What's New in Python 2.0} \release{0.05} *************** *** 115,118 **** --- 117,127 ---- case of any problems. + \item The \keyword{exec} statement, and various built-ins such as + \code{eval()}, \code{getattr()}, and \code{setattr()} will also + accept Unicode strings as well as regular strings. (It's possible + that the process of fixing this missed some built-ins; if you find a + built-in function that accepts strings but doesn't accept Unicode + strings at all, please report it as a bug.) + \end{itemize} *************** *** 142,146 **** \var{length})}, consisting of the resulting Unicode string \var{ustring} and the integer \var{length} telling how much of the ! string was consumed. \item \var{stream_reader} is a class that supports decoding input from --- 151,155 ---- \var{length})}, consisting of the resulting Unicode string \var{ustring} and the integer \var{length} telling how much of the ! 8-bit string was consumed. \item \var{stream_reader} is a class that supports decoding input from *************** *** 671,676 **** to; \code{3L * 'abc'} produces 'abcabcabc', and \code{ (0,1,2,3)[2L:4L]} produces (2,3). Long integers can also be used in ! various new places where previously only integers were accepted, such ! as in the \method{seek()} method of file objects. The subtlest long integer change of all is that the \function{str()} --- 680,688 ---- to; \code{3L * 'abc'} produces 'abcabcabc', and \code{ (0,1,2,3)[2L:4L]} produces (2,3). Long integers can also be used in ! various contexts where previously only integers were accepted, such ! as in the \method{seek()} method of file objects, and in the formats ! supported by the \verb|%| operator (\verb|%d|, \verb|%i|, \verb|%x|, ! etc.). For example, \code{"\%d" \% 2L**64} will produce the string ! \samp{18446744073709551616}. The subtlest long integer change of all is that the \function{str()} *************** *** 771,777 **** bytecode, limiting the size of source files. In particular, this affected the maximum size of literal lists and dictionaries in Python ! source; occasionally people who are generating Python code would run into this limit. ! A patch by Charles G. Waldman raises the limit from \verb|2^16| to \verb|2^{32}|. ! % ====================================================================== --- 783,802 ---- bytecode, limiting the size of source files. In particular, this affected the maximum size of literal lists and dictionaries in Python ! source; occasionally people who are generating Python code would run ! into this limit. A patch by Charles G. Waldman raises the limit from ! \verb|2^16| to \verb|2^{32}|. ! ! Three new convenience functions intended for adding constants to a ! module's dictionary at module initialization time were added: ! \function{PyModule_AddObject()}, \function{PyModule_AddIntConstant()}, ! and \function{PyModule_AddStringConstant()}. Each of these functions ! takes a module object, a null-terminated C string containing the name ! to be added, and a third argument for the value to be assigned to the ! name. This third argument is, respectively, a Python object, a C ! long, or a C string. ! ! A wrapper API was added for Unix-style signal handlers. ! \function{PyOS_getsig()} gets a signal handler and ! \function{PyOS_setsig()} will set a new handler. % ====================================================================== *************** *** 783,788 **** had to go through an arduous ritual of editing Makefiles and configuration files, which only really work on Unix and leave Windows ! and MacOS unsupported. Software users faced wildly differing ! installation instructions The SIG for distribution utilities, shepherded by Greg Ward, has --- 808,815 ---- had to go through an arduous ritual of editing Makefiles and configuration files, which only really work on Unix and leave Windows ! and MacOS unsupported. Python users faced wildly differing ! installation instructions which varied between different extension ! packages, which made adminstering a Python installation something of a ! chore. The SIG for distribution utilities, shepherded by Greg Ward, has |