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