Andrew M. Kuchling | a8defaa | 2001-05-05 16:37:29 +0000 | [diff] [blame] | 1 | \documentclass{howto} |
| 2 | |
| 3 | % $Id$ |
| 4 | |
| 5 | \title{What's New in Python 2.2} |
| 6 | \release{0.01} |
| 7 | \author{A.M. Kuchling} |
| 8 | \authoraddress{\email{amk1@bigfoot.com}} |
| 9 | \begin{document} |
| 10 | \maketitle\tableofcontents |
| 11 | |
| 12 | \section{Introduction} |
| 13 | |
| 14 | {\large This document is a draft, and is subject to change until the |
| 15 | final version of Python 2.2 is released. Currently it's not up to |
| 16 | date at all. Please send any comments, bug reports, or questions, no |
| 17 | matter how minor, to \email{amk1@bigfoot.com}. } |
| 18 | |
| 19 | This article explains the new features in Python 2.2. |
| 20 | Python 2.2 includes some significant changes that go far toward cleaning up |
| 21 | the language's darkest corners. |
| 22 | |
| 23 | This article doesn't attempt to provide a complete specification for |
| 24 | the new features, but instead provides a convenient overview of the |
| 25 | new features. For full details, you should refer to 2.2 documentation |
| 26 | such as the Library Reference and the Reference Guide, or to the PEP |
| 27 | for a particular new feature. |
| 28 | |
| 29 | The final release of Python 2.2 is planned for October 2001. |
| 30 | |
| 31 | %====================================================================== |
| 32 | \section{PEP 234: Iterators} |
| 33 | |
| 34 | XXX |
| 35 | |
| 36 | \begin{seealso} |
| 37 | |
| 38 | \seepep{234}{Iterators}{Written by Ka-Ping Yee and GvR; implemented |
| 39 | by the Python Labs crew, mostly by GvR and Tim Peters.} |
| 40 | |
| 41 | \end{seealso} |
| 42 | |
| 43 | %====================================================================== |
Andrew M. Kuchling | a43e703 | 2001-06-27 20:32:12 +0000 | [diff] [blame^] | 44 | \section{PEP 255: Simple Generators} |
| 45 | |
| 46 | XXX |
| 47 | |
| 48 | \begin{seealso} |
| 49 | |
| 50 | \seepep{255}{Simple Generators}{Written by Neil Schemenauer, |
| 51 | Tim Peters, Magnus Lie Hetland. Implemented mostly by Neil |
| 52 | Schemenauer, with fixes from the Python Labs crew, mostly by GvR and |
| 53 | Tim Peters.} |
| 54 | |
| 55 | \end{seealso} |
| 56 | |
| 57 | %====================================================================== |
Andrew M. Kuchling | a8defaa | 2001-05-05 16:37:29 +0000 | [diff] [blame] | 58 | \section{PEP 252: Type and Class Changes} |
| 59 | |
| 60 | XXX |
| 61 | |
| 62 | \begin{seealso} |
| 63 | |
| 64 | \seepep{252}{Making Types Look More Like Classes}{Written and implemented |
| 65 | by GvR.} |
| 66 | |
| 67 | \end{seealso} |
| 68 | |
| 69 | %====================================================================== |
Andrew M. Kuchling | a43e703 | 2001-06-27 20:32:12 +0000 | [diff] [blame^] | 70 | \section{Unicode Changes} |
| 71 | |
| 72 | XXX I have to figure out what the changes mean to users. |
| 73 | (--enable-unicode configure switch) |
| 74 | |
| 75 | References: http://mail.python.org/pipermail/i18n-sig/2001-June/001107.html |
| 76 | and following thread. |
| 77 | |
| 78 | |
| 79 | %====================================================================== |
Andrew M. Kuchling | a8defaa | 2001-05-05 16:37:29 +0000 | [diff] [blame] | 80 | \section{New and Improved Modules} |
| 81 | |
| 82 | \begin{itemize} |
| 83 | |
| 84 | \item XXX |
| 85 | |
| 86 | \end{itemize} |
| 87 | |
| 88 | |
| 89 | %====================================================================== |
| 90 | \section{Other Changes and Fixes} |
| 91 | |
| 92 | XXX |
| 93 | |
| 94 | \begin{itemize} |
| 95 | |
| 96 | \item XXX Nested scoping enabled by default |
| 97 | |
| 98 | \item XXX C API: Reorganization of object calling |
| 99 | |
Andrew M. Kuchling | 3b923fc | 2001-05-19 19:35:46 +0000 | [diff] [blame] | 100 | \item XXX .encode(), .decode() string methods. Interesting new codecs such |
| 101 | as zlib. |
| 102 | |
Andrew M. Kuchling | a8defaa | 2001-05-05 16:37:29 +0000 | [diff] [blame] | 103 | %Original log message: |
| 104 | |
| 105 | %The call_object() function, originally in ceval.c, begins a new life |
| 106 | %as the official API PyObject_Call(). It is also much simplified: all |
| 107 | %it does is call the tp_call slot, or raise an exception if that's |
| 108 | %NULL. |
| 109 | |
| 110 | %The subsidiary functions (call_eval_code2(), call_cfunction(), |
| 111 | %call_instance(), and call_method()) have all been moved to the file |
| 112 | %implementing their particular object type, renamed according to the |
| 113 | %local convention, and added to the type's tp_call slot. Note that |
| 114 | %call_eval_code2() became function_call(); the tp_slot for class |
| 115 | %objects now simply points to PyInstance_New(), which already has the |
| 116 | %correct signature. |
| 117 | |
| 118 | %Because of these moves, there are some more new APIs that expose |
| 119 | %helpers in ceval.c that are now needed outside: PyEval_GetFuncName(), |
| 120 | %PyEval_GetFuncDesc(), PyEval_EvalCodeEx() (formerly get_func_name(), |
| 121 | %get_func_desc(), and eval_code2(). |
| 122 | |
| 123 | \end{itemize} |
| 124 | |
| 125 | |
| 126 | |
| 127 | %====================================================================== |
| 128 | \section{Acknowledgements} |
| 129 | |
| 130 | The author would like to thank the following people for offering |
| 131 | suggestions on various drafts of this article: No one yet. |
| 132 | |
| 133 | \end{document} |