Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 77ad829

Browse files
committed
[Bug #780231] One of the changes described in the 2.3 "What's New" document
actually occurred in 2.2. Move the description to whatsnew22.tex. [Bugfix candidate -- I'll backport to 2.3 (another 2.2 bugfix seems unlikely)
1 parent 9e78d1e commit 77ad829

2 files changed

Lines changed: 27 additions & 27 deletions

File tree

Doc/whatsnew/whatsnew22.tex

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1226,6 +1226,33 @@ \section{Interpreter Changes and Fixes}
12261226
\cfunction{PyThreadState_Next()} allow looping over all the thread
12271227
states for a given interpreter. (Contributed by David Beazley.)
12281228

1229+
\item The C-level interface to the garbage collector has been changed
1230+
to make it easier to write extension types that support garbage
1231+
collection and to debug misuses of the functions.
1232+
Various functions have slightly different semantics, so a bunch of
1233+
functions had to be renamed. Extensions that use the old API will
1234+
still compile but will \emph{not} participate in garbage collection,
1235+
so updating them for 2.2 should be considered fairly high priority.
1236+
1237+
To upgrade an extension module to the new API, perform the following
1238+
steps:
1239+
1240+
\begin{itemize}
1241+
1242+
\item Rename \cfunction{Py_TPFLAGS_GC} to \cfunction{PyTPFLAGS_HAVE_GC}.
1243+
1244+
\item Use \cfunction{PyObject_GC_New} or \cfunction{PyObject_GC_NewVar} to
1245+
allocate objects, and \cfunction{PyObject_GC_Del} to deallocate them.
1246+
1247+
\item Rename \cfunction{PyObject_GC_Init} to \cfunction{PyObject_GC_Track} and
1248+
\cfunction{PyObject_GC_Fini} to \cfunction{PyObject_GC_UnTrack}.
1249+
1250+
\item Remove \cfunction{PyGC_HEAD_SIZE} from object size calculations.
1251+
1252+
\item Remove calls to \cfunction{PyObject_AS_GC} and \cfunction{PyObject_FROM_GC}.
1253+
1254+
\end{itemize}
1255+
12291256
\item A new \samp{et} format sequence was added to
12301257
\cfunction{PyArg_ParseTuple}; \samp{et} takes both a parameter and
12311258
an encoding name, and converts the parameter to the given encoding

Doc/whatsnew/whatsnew23.tex

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2136,33 +2136,6 @@ \section{Build and C API Changes}
21362136

21372137
\begin{itemize}
21382138

2139-
\item The C-level interface to the garbage collector has been changed
2140-
to make it easier to write extension types that support garbage
2141-
collection and to debug misuses of the functions.
2142-
Various functions have slightly different semantics, so a bunch of
2143-
functions had to be renamed. Extensions that use the old API will
2144-
still compile but will \emph{not} participate in garbage collection,
2145-
so updating them for 2.3 should be considered fairly high priority.
2146-
2147-
To upgrade an extension module to the new API, perform the following
2148-
steps:
2149-
2150-
\begin{itemize}
2151-
2152-
\item Rename \cfunction{Py_TPFLAGS_GC} to \cfunction{PyTPFLAGS_HAVE_GC}.
2153-
2154-
\item Use \cfunction{PyObject_GC_New} or \cfunction{PyObject_GC_NewVar} to
2155-
allocate objects, and \cfunction{PyObject_GC_Del} to deallocate them.
2156-
2157-
\item Rename \cfunction{PyObject_GC_Init} to \cfunction{PyObject_GC_Track} and
2158-
\cfunction{PyObject_GC_Fini} to \cfunction{PyObject_GC_UnTrack}.
2159-
2160-
\item Remove \cfunction{PyGC_HEAD_SIZE} from object size calculations.
2161-
2162-
\item Remove calls to \cfunction{PyObject_AS_GC} and \cfunction{PyObject_FROM_GC}.
2163-
2164-
\end{itemize}
2165-
21662139
\item The cycle detection implementation used by the garbage collection
21672140
has proven to be stable, so it's now been made mandatory. You can no
21682141
longer compile Python without it, and the

0 commit comments

Comments
 (0)